Rendering high-res frames by assembling several quadrant render passes

Years ago I remember rendering some high-res animation frames for film by rendering each quadrant of the scene separately and combining the four pieces. Now I can’t remember how to do that. It’s basically fiddling with the window/viewport settings, isn’t it? I want to produce a frame that is twice (or 4x,8x etc) larger than the original, but otherwise the same. Any tips on the easiest way to do that?


Projection matrix.

With modern OpenGL (3.0+ or the ARB_framebuffer_object extension), you’d use a framebuffer object rather than rendering to the window. If you have enough video memory, you might be able to render it in one pass. Otherwise, using multiple framebuffers in a round-robin should be faster than using a single framebuffer, as you can read out the previous tile while rendering the next one.

Ok thanks – but how exactly do I need to change the projection matrix so that it produces a quarter of my original scene?

Put a scale and translation in front of it:

glTranslatef(nx-(2*x+1), ny-(2*y+1), 0);
glScalef(nx, ny, 1);

x and y are the tile indices, nx and ny are the number of tiles in each direction.