I am a true “OpenGL coding: beginner”, been following several threads and even mucking with some tutorials on NeHe.

I was wondering if someone can shed some light on eliminating the “flipping” of images with gluPerspective/glRoatef etc…

if I do the following

f += 0.1f;

my image will go away from me, then “flip” and come from behind me then away again.

that is

I make a triangle with a quad next to it, as it goes down the Z axis the triangle is on the left and the quad is on the right. Once the image is gone, it will flip (quad on the left and traingle on the right) and come from behind me (per say) into the screen.

This happens with textures as well, if I rotate an image the texture gets flipped (upside down etc.)

Yes, you guesed it I am a newbie!


The variable that you are changing represents the field of view of the camera. Once that value passes 180 everything will become flipped. If you are trying to zoom in and out of the scene you want to keep the field of view between 0 and 180. Hope that helps.