Make Ortho camera see the entire scene

Hey there, I want to view my pointcloud in ortho mode so distance does not effect it, but I need to see all the points at once. In ortho mode I can’t set FOV or aspect ratio, so how can I widen my view to see all my points at once?

Right now my solution if to draw into a FBO that is twice the size of the screen and then draw that FBO to the size of the screen, but this seems rather silly and it lowers my fps. Is there a better way?

I have an improved approach:

ofScale(cameraZoom, cameraZoom, -1);

Thanks @Caroline_Record, works flawlessly.

But it’s worth mentioning for someone who needs this that units of cameraZoom parameter in this approach are a bit tricky. You need to treat this literally like ‘zoom’ – so if you need to ‘move back twenty times’ to see bigger picture you need to do ofScale(.05, .05, -1);.

EDIT: Also I’m not sure why you put -1 value here… This causes entire scene to weirdly stretch in Z direction. It works best for me with equal scaling:

ofScale (.1);

Cheers, Teo