[SOLVED] How to "Zoom" an ortho camera?

I'm having trouble "zooming" using a camera with parallel projection set.



Changing camera position (obviously) doesn't seem to work, and I've tried setting the left, right, top, bottom frustum values (which I assume equates to changing the FOV) but nothing seems to work.



Any ideas out there?

Depending on the effect you want to achieve, use scale, or translate the root object of your scene. Or use regular projection :stuck_out_tongue:

This is what I use (parallell projection, not ortho):



float aspect = (float) display.getWidth() / display.getHeight();
float invZoom = 20f;
cam.setParallelProjection( true );
cam.setFrustum( 0, 150, -invZoom * aspect, invZoom * aspect, -invZoom, invZoom );
cam.update();
cam.apply();

Thank you both for the quick replies,



this is what got it working for me:


cam.setFrustum( 0, 150, -invZoom * aspect, invZoom * aspect, -invZoom, invZoom );