Search found 161 matches
- 08 Jun 2018 21:18
- Forum: DOS Batch Forum
- Topic: Dragon Curve using L-System
- Replies: 0
- Views: 18834
Dragon Curve using L-System
Hello, I recently learned about L-Systems, and have created a dragon curve. There are many other visualizations that I got from http://paulbourke.net/fractals/lsys/ . Please enjoy :) F + - [ ] are the characters and each character does 1 thing F : Move forward + : Rotate Right - : Rotate Left [ : PU...
- 04 Jun 2018 14:02
- Forum: DOS Batch Forum
- Topic: Dos Batch Math Library
- Replies: 68
- Views: 92324
Re: Dos Batch Math Library
Thank you so much for the resources! I will research this.
- 30 May 2018 06:58
- Forum: DOS Batch Forum
- Topic: Dos Batch Math Library
- Replies: 68
- Views: 92324
Re: Dos Batch Math Library
Hey, I wanted to share something I made last night. I thought maybe this would be useful FIXED! Accuracy is 100% https://gyazo.com/1765c4579c80f2688789b12901d762ad.png @echo off & setlocal enableDelayedExpansion for /l %%a in (1,1,20) do ( set /a "rnd1=!random! %% 49 + 1", "rnd2=!random! %% 49 + 1" ...
- 22 May 2018 15:57
- Forum: DOS Batch Forum
- Topic: Cross vector product algorithm issue? Need help
- Replies: 7
- Views: 6014
Re: Cross vector product algorithm issue? Need help
What a great alternative! Thank you Aacini, and Penpen for your help.
- 16 May 2018 10:36
- Forum: DOS Batch Forum
- Topic: Cross vector product algorithm issue? Need help
- Replies: 7
- Views: 6014
Re: Cross vector product algorithm issue? Need help
I know that writting batch macros makes it harder to read, so here is the pseudo-code in qBasic. FUNCTION FNcross (x1, y1, x2, y2) FNcross = x1 * y2 - y1 * x2 END FUNCTION SUB Intersect (x1, y1, x2, y2, x3, y3, x4, y4, x, y) x = FNcross(x1, y1, x2, y2) y = FNcross(x3, y3, x4, y4) det = FNcross(x1 - ...
- 09 May 2018 09:20
- Forum: DOS Batch Forum
- Topic: Visualize a clock
- Replies: 6
- Views: 6438
Re: Visualize a clock
I love working with batch files, but I've got to be honest, this task is completely unnecessary and wasteful. At all times whilst using my PC, there's a direct click to open a clock which gives me everything I need! https://i.imgur.com/m9cebEG.gif By no means am I trying to reproduce a BETTER clock...
- 07 May 2018 19:55
- Forum: DOS Batch Forum
- Topic: Cross vector product algorithm issue? Need help
- Replies: 7
- Views: 6014
Cross vector product algorithm issue? Need help
Hello everyone I have been experimenting with vertexes, and have come to simulate 3rd, 2nd, and 1st person view. I'm having trouble with a piece of the algorithm though. I need to clip the image from view if it is NOT in front of the player IF the view is 1st person (line12) Clipping the image out o...
- 06 May 2018 10:37
- Forum: DOS Batch Forum
- Topic: Visualize a clock
- Replies: 6
- Views: 6438
Visualize a clock
Hello all ^-^ A great exercise is to visualize a clock in code. I suggest you all try it! Enjoy! WIN 10 ONLY! Excuse the flicker, I believe it is from GYAZO gif https://gyazo.com/52fc6c13f389f8d8c11f588833d5d239.gif https://gyazo.com/c9ed849947be13a62aacea7190035173.gif @echo off & setlocal EnableDe...
- 04 May 2018 21:38
- Forum: DOS Batch Forum
- Topic: drawing things with smoothStep algorithm
- Replies: 1
- Views: 2711
drawing things with smoothStep algorithm
I believe I finally have created (successfully) CLAMP and SMOOTHSTEP macros for graphic drawing in pure batch. The website I used to check my results are from http://www.fundza.com/rman_shaders/smoothstep/ In computer graphics, clamping is the process of limiting a position to an area. Unlike wrappi...
- 03 May 2018 16:55
- Forum: DOS Batch Forum
- Topic: Algorithmic conditions, and returns????
- Replies: 15
- Views: 11935
Re: Algorithmic conditions, and returns????
But if what's in my head is correct, then XOR would return BOOL= 0 during this case. Correct. set "XOR(b1,b2)=((b1+b2)&1)" The least significant bit is 0 if the result of the addition was either 0 or 2. But Batch already supports binary XOR, hence ... set "XOR(b1,b2)=(b1^b2)" ... would have been ea...
- 03 May 2018 14:36
- Forum: DOS Batch Forum
- Topic: Algorithmic conditions, and returns????
- Replies: 15
- Views: 11935
Re: Algorithmic conditions, and returns????
@echo off &setlocal REM ----- return 0 if false or 1 if true ----- set "LSS(x,y)=(((x-y)>>31)&1)" &REM < set "LEQ(x,y)=((~(y-x)>>31)&1)" &REM <= set "GTR(x,y)=(((y-x)>>31)&1)" &REM > set "GEQ(x,y)=((~(x-y)>>31)&1)" &REM >= set "EQU(x,y)=(((~(y-x)>>31)&1)&((~(x-y)>>31)&1))" &REM == set "NEQ(x,y)=(((...
- 03 May 2018 13:14
- Forum: DOS Batch Forum
- Topic: And now dos batch color secrets?
- Replies: 20
- Views: 21782
Re: And now dos batch color secrets?
Einstein, my friend, where have you been? Your work on colors has inspired me over time.
- 29 Apr 2018 21:57
- Forum: DOS Batch Forum
- Topic: And now dos batch color secrets?
- Replies: 20
- Views: 21782
Re: And now dos batch color secrets?
Sorry to dig this up, but I thought maybe it might be useful to post a VT100 solution for WIN 10 PCs.. HSL https://gyazo.com/0883da98ab6f230068823e8a96e07681.png @echo off & setlocal enabledelayedexpansion mode 90,60 for /F %%a in ('echo prompt $E^| cmd') do set "ESC=%%a" Set /a s=10000, v1=10000 Fo...
- 27 Apr 2018 11:24
- Forum: DOS Batch Forum
- Topic: An apology and one final question to clear a matter up
- Replies: 13
- Views: 9910
Re: An apology and one final question to clear a matter up
Probably because it's more trivial than your initial problem. I assume he figured you could handle it..
- 23 Apr 2018 20:20
- Forum: DOS Batch Forum
- Topic: 7 zip command help.
- Replies: 5
- Views: 5259
Re: 7 zip command help.
I, at one point, considered breaking everything down for him. Then, after I reread everything, I realized everyone had already given him exactly what he needed, and he neglected to utilize it.