Reading frames in real time

Hello,
We need to take the frames of an OpenGL animation and to send them downstream, for example to feed a streaming encoder in order to view the animation in a web page or to send the frames to a professional video board. The problem is glReadPixels() is very slow and we hardly get more than 2 frames per second. The procedure we use is: Render frame, ReadPixels, dispatch the frame.
Can anybody figure out how to improve the frame rate? I have been told about manufacturer specific extensions to make asynchronous glReadPixels calls. Can anybody tell me anything about this approach or about a different one?
Thanks.

download the NVIDIA SDK.
look into OpenGLSDK\src\shared folder. there is a file called “moviemaker.cpp”. that’s exactly what you are looking for.

Make sure you read the EXACT format that the frame buffer is actually running in.

If you use 32-bit frame buffer, this would usually be GL_UNSIGNED_CHAR, GL_BGRA.

Also make sure you align your read buffers reasonably.

Do a search on “glReadPixels” in this forum.