[Qt-interest] HelloGL: Q's surfaces are inverted?
Rui Maciel
rui.maciel at gmail.com
Mon Nov 16 17:35:45 CET 2009
While fooling around with the HelloGL example[1] from Qt's examples site I've stumbled on what appears to be
a problem in the demo program. Although it compiles and runs perfectly as expected, the orthographic
projection is set as:
glOrtho(-0.5, +0.5, +0.5, -0.5, 4.0, 15.0);
...while glOrtho()'s parameters[2] are (left, right, bottom, top), which means that every primitive will be
rendered in an inverted position. Yet, when the parameters passed to glOrtho() are straightened out the Q's
primitives appear facing the other way, which means that, with backface culling enabled, the only faces which
will be rendered are those which should be hidden.
Is this some sort of bug or am I missing something?
Rui Maciel
[1]http://doc.trolltech.com/4.5/opengl-hellogl.html
[2]http://www.opengl.org/sdk/docs/man/xhtml/glOrtho.xml
More information about the Qt-interest-old
mailing list