Let's say I have a 2D OpenGL app which uses a simple orthogonal projection where (0,0,0) corresponds to the bottom left corner of the screen, and (480,640,0) corresponds to the top right.
Now say I want to make my 2D app a bit 3D, i.e. introduce little 3D effects such as things falling into place from above the screen. To do this I need a perspective projection where everything on the usual plane of rendering (z=0) looks identical to when the orthogonal projection was being used.
Anyone know how to create such a projection? The math appears to be slightly beyond me. Presumably I want my frustum's far plane to be z=0, where (0,0,0) corresponds to the bottom left pixel, but glFrustum() et al only let me specify coordinates for the near plane. How do I choose sensible near and far values? I've tried using glFrustum() and gluLookAt() to look at the origin from some point above the screen, but how do I choose the eye point?