zooming with glortho should be same as with glPerspective?

Started by
10 comments, last by sjaakiejj 12 years, 1 month ago

Got it. My analogy of the concept was off a bit, and I was taking "zooming in" to be a non-mechanical concept, and the only way I could think of enlarging an object from that standpoint was by translation smile.png


Considering how orthogonal projection works you must realize that distance will not change how large the object appears, right? So as long as your object is perfectly centered, you can translate back and forth as much as you like without seeing any difference. Until the object gets clipped against the near and far plane.

If you want to zoom, just decrease your fov or limit your ortho projection to a smaller area. You don't run into clipping issues and it's a lot less messy.

You will still not find a simple relationship for perspective and ortho zoom without considering the objects distance to the camera in your calculation. Even if you find that matching set of zoom factors, where the object appears equally large in both projections... move it closer or farther away and your numbers won't work anymore.
f@dzhttp://festini.device-zero.de
Advertisement

[quote name='sjaakiejj' timestamp='1330943918' post='4919410']
Got it. My analogy of the concept was off a bit, and I was taking "zooming in" to be a non-mechanical concept, and the only way I could think of enlarging an object from that standpoint was by translation smile.png


Considering how orthogonal projection works you must realize that distance will not change how large the object appears, right? So as long as your object is perfectly centered, you can translate back and forth as much as you like without seeing any difference. Until the object gets clipped against the near and far plane.
[/quote]
Yes, due to the fact the view frustrum is in fact a cube/rectangle (e.g. near and far plane are of equal size)


If you want to zoom, just decrease your fov or limit your ortho projection to a smaller area. You don't run into clipping issues and it's a lot less messy.

You will still not find a simple relationship for perspective and ortho zoom without considering the objects distance to the camera in your calculation. Even if you find that matching set of zoom factors, where the object appears equally large in both projections... move it closer or farther away and your numbers won't work anymore.
[/quote]
As mentioned before, I mainly looked at replacing the glTranslate function. As I never use Orthographic views myself, I didn't really think too much about what translation means in such a projection.

This topic is closed to new replies.

Advertisement