cut frustum

Hi! I need to resize the frustum in this particoular way:

I was thinking to make something like this:

but I don’t know if is the best way to do it, and how calculate it… probably using the function ReadPixels, but how can I calculate the correct left coordinates ?

Maybee you are looking for glViewport(), custom clip planes or the scissor test?

You can not do that with the standard glFrustum, glPerspective functions because near and far clipping planes have to be parallel to the framebuffer.

Perhaps this could be of some help?

http://www.terathon.com/code/oblique.php

http://www.terathon.com/gdc07_lengyel.ppt