Stereo display with OpenGL

How is it possible to create a stereo display in even-odd mode (I don’t know the real name - it’s the mode where odd lines are meant for one eye and even ones for the other) in OpenGL? I need to write a program for a HMD and I’d prefer using OpenGL to Direct3D 7 (the HMD driver patches D3D7 to produce stereo display even for normal programs).

Any help would be appreciated.

Got a link for you:

Check Michal Husak’s site at

He uses a stencil mask to mask either odd or even lines and draws the scene twice (once from each viewpoint) with a different stencil function each time.