[SDL] [DEMO] Minimal world engine, updated
Daniel Phillips
phillips at arcor.de
Thu Jan 23 15:44:01 PST 2003
I cleaned up a number of issues with the world engine demo.
For now, I worked around the problem with glXChooseVisual sometimes refusing
to set a high resolution depth buffer by changing the shadow demo to use
glPolygonOffset. This is the wrong way to draw shadows anyway; the point of
that demo is really more how to set up a shadow transformation matrix.
Now I don't specify any gl attributes at all and just let glXChooseVisual
hand me whatever minimal gl configuration it sees fit. This seems to be more
robust, though there is always the possibility that on some platforms
glXChooseVisual will look at all those zero attributes and freak out anyway.
This is issue is by no means resolved, I just avoided it for now.
There's a new demo world, simple.c, that uses 8 lines of straight-up OpenGL
and 5 lines of glue to define a world containing a single multicolored
triangle. This was originally a demo by Mark Kilgard, comparing OpenGL+Glut
to Direct3D+Directx to see how easy it is to draw something simple. Well,
it's a lot simpler now.
I'd appreciate some more feedback/complaints about build problems at this
point, and could somebody please try compiling this on Windows, and tell me
how badly my C code breaks VCC.
The source is here:
nl.linux.org/~phillips/world/world.zip
Regards,
Daniel
More information about the SDL
mailing list