PDA

View Full Version : counterclockwise/clockwise orientation



mochi
08-01-2001, 06:33 PM
Hi ...

I had always thought that the default orientation for GL_POLYGON vertices is anticlockwise.
However, my compiler seems to think otherwise and produce the image only when I do clockwise.
I'm using an ANSI C++ compiler, HP-Ux.


Please help.
Thanks =>

Aster
08-01-2001, 08:13 PM
Just make a call to glFrontFace(GL_CW) to set your front faces to clockwise direction.

[This message has been edited by Aster (edited 08-01-2001).]

mochi
08-01-2001, 09:38 PM
I did that .... my image disappear after that ... sigh ... dunno why ....

Deiussum
08-02-2001, 07:01 AM
Two thoughts:

1) Are you absolutely sure you are specifying the points counter-clockwise?

2) How do you setup your projection matrix? For instance, you do an ortho projection and make left<right or top<bottom, the coordinate system gets flipped.