03-26-2005, 04:47 AM
I was doing my normal playing with some new code, in this case 3D stuff, when by complete accident made a really, really beautiful effect..
Its one PSET flying around the screen at 6600 FPS.....
Hard to explain, just watch, Enjoy!!...
Its one PSET flying around the screen at 6600 FPS.....
Hard to explain, just watch, Enjoy!!...
Code:
SCREEN 19, 32, 2, 1
x! = 150
y! = 150
z! = 150
centx = 400
centy = 300
LENS = 256 ' centz
ax = 0
ay = 0
az = 0
T! = TIMER
DO
press$ = INKEY$
rx! = ax * 3.14/180
ry! = ay * 3.14/180
rz! = az * 3.14/180
cx! = COS(rx!)
sx! = SIN(rx!)
cy! = COS(ry!)
sy! = SIN(ry!)
cz! = COS(rz!)
sz! = SIN(rz!)
ny! = (y! * cx!)-(z! * sx!)
nz! = (z! * cx!)+(y! * sx!)
y! = ny!
z! = nz!
nz! = (z! * cy!)-(x! * sy!)
nx! = (x! * cy!)+(z! * sy!)
x! = nx!
nx! = (x! * cz!)-(y! * sz!)
ny! = (y! * cz!)+(x! * sz!)
ay = (ay + 1) MOD 360
ax = (ax + 1) MOD 360
az = (az + 1) MOD 360
PSET (centx + nx!, centy - ny!), RGB(z!, z!, z! )
F = F + 1
LOOP UNTIL press$ = CHR$(27)
PRINT "Average FPS:"; F / (TIMER - T!)
SLEEP