Clipped view of projection
My ReshapeFunc function looks like this - but it isn't working well
[Edited by - versus5 on November 11, 2009 7:52:47 PM]
void reshape(int w,int h){ GLfloat aspectRatio; if(h==0) h=1; glMatrixMode(GL_PROJECTION); glLoadIdentity(); glViewport (0, 100, (GLsizei) w, (GLsizei) h); gluOrtho2D(0, 800, 0, 500 ); //small clipped view //--this part is not working> glLoadIdentity(); glViewport (0, 0, 100, 100); gluOrtho2D(0, 800, 0, 500 ); //--this part is not working < glFlush();}
[Edited by - versus5 on November 11, 2009 7:52:47 PM]
You're passing a width value of 0 into glViewport, that's probably not what you want.
Also, why are you setting the viewport/ortho matrix, and then immediately overwriting those settings?
Also, why are you setting the viewport/ortho matrix, and then immediately overwriting those settings?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement