View Full Version : How to define projection limits for glFrustum?
Hi all,
I have a question about glFrustum. Given a bounding box of geometry model, how to define "left, right, bottom, top, near, far" in glFrustum based the bounding box.
Thanks a lot!
Sophia
Yes, I meeted also this question. When I use orthographic projection, everything is ok, but the weird thing comes out when using glFrustum. Specially, I found the selection of near and far has a lot of influence on image rendering.
Sorry that I can not give you any help, and thank you to submit the question that I want to know also.
roffe
09-19-2003, 12:19 PM
Originally posted by Sophia:
I have a question about glFrustum. Given a bounding box of geometry model, how to define "left, right, bottom, top, near, far" in glFrustum based the bounding box.
bboxWidth = right-left
bboxHeight = top-bottom
by varying your near plane you can pick what fov you like
A more intuitive function might be gluPerspective (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/opengl/glufnc01_6m79.asp) . A great demo for getting to know these functions are nate robbins's projection tut (http://www.xmission.com/~nate/tutors.html) .
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.