Minimalistic procedual Sinus Rendering

Post your FreeBASIC source, examples, tips and tricks here. Please don’t post code without including an explanation.
Post Reply
mrminecrafttnt
Posts: 105
Joined: Feb 11, 2013 12:23

Minimalistic procedual Sinus Rendering

Post by mrminecrafttnt »

I found a way to render with sinus.

Code: Select all

dim as double x,y,z
screenres 640,480
screenlock
do
    y=sin(y)*320+320
    x=sin(x)*240+240
    pset(y,x),y imp x
    z+=1
loop until z = 7400000
print "Press a key to exit"
screenunlock
sleep

Code: Select all

dim as double x,y,z,o
screenres 640,480

do
    o+=0.00000035
    y=sin(y)*320+320
    x=sin(x)*240+240
    pset(y,x),y imp x imp o
'    z+=1
loop until inkey <> ""
print "Press a key to exit"

sleep
Post Reply