[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[pygame] OpenGL Updates



ok, i know several of you have already been digging in around
with the pygame opengl stuff. i've just added a pretty good set
of opengl stuff into pygame. i don't think we'll really need
any more than this. although stuff like accumulation buffers
cannot be set, we'll worry about that a little later.

anyways, this new functionality is all in the current cvs
(and cvs snapshot). Basically you just add the "OPENGL" flag
to your set_mode() call and you are all set. you will also
probably want to pass the DOUBLEBUF flag with OPENGL, since
single-buffering with opengl is never too pretty.

the pygame.display.flip() function properly handles the GL
swapping. the display and Surface functions should raise an
exception if they do not work on opengl surfaces.

there is also a new "glcube.py" demo in the examples directory
that makes use of the new functionality.

note that all opengl calls are made through the pyopengl library.
using this library is almost exactly the same as using C OpenGL,
so it's easy to learn.

anyways, this opengl stuff really could use some testing out.
there might be plenty of wierd cases and stuff, so grab, try,
and report.

also note that the "undocumented" opengl functions in pygame are
now gone. (try to hold back the tears for our little hidden friends)

thanks to kevin for bearing the brunt of the 'usability testing'


____________________________________
pygame mailing list
pygame-users@seul.org
http://pygame.seul.org