|
Post by PeterMaria on Dec 15, 2015 12:09:43 GMT -5
Hello, it's a worm.
glMatrixMode (GL_PROJECTION) glLoadIdentity() glOrtho(0,640,480,0,-1,1) glMatrixMode (GL_MODELVIEW) glDisable(GL_DEPTH_TEST)
Sub FillCircle(x#,y#,r1#) dim r#=r1#/2, t# glBegin(GL_TRIANGLE_FAN) glVertex2f(x#, y#) For t#=0 to 360 step 5 glVertex2f(x#+sin(t#)*r#, y#+cos(t#)*r#) Next glEnd() End Sub
Sub xPoint(x, y) dim c for c=0 to 36 fillcircle(c+x, c+y, 20) next End Sub
dim t#, a#, xp#, yp#, zp#, xs#, ys#
while scankeydown(27)=0 glclearcolor(.5, .5, .5, 1) glclear(GL_COLOR_BUFFER_BIT) for t#=0 to 1 Step .01 xp# = 100 * cos(a#*t#) yp# = 100 * sin(t#*4) zp# = sin(t#*100) xs# = 300 + xp# ys# = 240 - yp# glcolor3ub(zp#*10,zp#*10,zp#*10) xPoint(xs#-50, ys#) next a# = a# + .6 if a# >=16 then a#=-a#: end if swapbuffers() waittimer(10) wend
|
|
|
Worm
Dec 15, 2015 18:44:26 GMT -5
Post by matthew on Dec 15, 2015 18:44:26 GMT -5
It looks too big to be a worm, Peter. :-)
Did you create a new account?
|
|
|
Worm
Dec 15, 2015 20:47:15 GMT -5
Post by PeterMaria on Dec 15, 2015 20:47:15 GMT -5
Hi Matthew,
Yes I did.
|
|