Library: glWrapper
Posted: Sun Jan 11, 2004 3:31 pm
PUREBASIC glWrapper
With this tiny library you can use all GL-Commands and GLU-Routines
(that originally require doubles) with floats, making them usable
within PureBasic.
It works through simple casting, so values are 'cut'.
Often, the extra-precision isn't needed anyway.
Don't like it? Don't use it!
Note: To use the commands, call them with an additional underscore,
e.g. glOrtho__() instead of glOrtho_().
I wrote this back in june 2002 and finally decided to release this
because I still see lots of questions in the forum regarding OpenGL.
Maybe you'll find this useful. Use at your own risk!
I hope I didn't forget anything important, here's a list of the
wrapped commands and routines:
Get it here: http://files.connection-refused.org/glWrapper.zip
With this tiny library you can use all GL-Commands and GLU-Routines
(that originally require doubles) with floats, making them usable
within PureBasic.
It works through simple casting, so values are 'cut'.
Often, the extra-precision isn't needed anyway.
Don't like it? Don't use it!
Note: To use the commands, call them with an additional underscore,
e.g. glOrtho__() instead of glOrtho_().
I wrote this back in june 2002 and finally decided to release this
because I still see lots of questions in the forum regarding OpenGL.
Maybe you'll find this useful. Use at your own risk!
I hope I didn't forget anything important, here's a list of the
wrapped commands and routines:
Code: Select all
GL Commands :
-------------
( only those without corresponding float versions, e.g. you
won't find glColor3d() because you can use glColor3f() )
glClearDepth()
glDepthRange()
glClipPlane()
glFrustum()
glGetClipPlane()
glOrtho()
GLU Routines :
--------------
gluCylinder()
gluDisk()
gluLookAt()
gluOrtho2D()
gluPartialDisk()
gluPerspective()
gluPickMatrix()
gluProject()
gluSphere()
gluTessVertex()
gluUnProject()
Get it here: http://files.connection-refused.org/glWrapper.zip