What's the easiest way?

BlitzMax Forums/OpenGL Module/What's the easiest way?

Blitzed090604(Posted 2005) [#1]
I learned Blitz3d by creating a textured working model of our solar system. It was a great experience and helped me learn the language while having fun.

That being said (and I feel like I'm opening a whole can of worms here...we'll see) what is the easiest way to create a sphere in BlitzMax using openGL commands.

Thanks for your input ahead of time.


Chris C(Posted 2005) [#2]
purests will howl, but have a look @ glew

Const GLU_FILL=100012 ' glu constant
Global sphereQuad:Int Ptr
sphereQuad = Int Ptr gluNewQuadric( )
gluQuadricDrawStyle( sphereQuad, GLU_FILL )
gluQuadricTexture(sphereQuad,True)
...
gluSphere( sphereQuad, obj.size[x], 16, 16 )

just ripped those fragments out of the tutorial I put on blitwiki
http://www.blitzwiki.org/index.php/OpenGL_Introduction
theres a zip of some code/textures to get you started

hope it helps