I have a question regarding glOrtho:
glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble near, GLdouble far);
now when the “near” and “far” parameters have different signs - like the “near” value is negative and “far” value positive and the eye is at the origin, then the eye is actually inside the viewing volume. In this case, where is the projection plane and how does hidden surface removal take place?
any insight will be much appreciated. thanks.
Why do you want to know?
I guess the depth buffer will work as normal but setting the near value negative will throw away some precision. I do not see what you will get in return.
Objects outside the view frustum is not a problem with or without enabling the depth buffer.
It doesn’t make any sense and it isn’t allow I think.
The screen is always at z=0. So if you set zNear less than 0 (which gluOrtho2D does by the way), then it puts that plane behind the viewpoint.
It would be like if your monitor is the film in a camera…
[This message has been edited by Michael Steinberg (edited 04-14-2001).]