how to read from back buffer

Hi,
I have to render a scene and then use spherical or cubic mapping for getting a reflective object in the scene, what i would like to know is this.

How do i (in opengl) render a scene and then take a snapshotof it and use it as a texture in realtime. I need to do this for every frame in spherical map, so help me.

thankyou for your time
Regards

Use glReadPixels to do it - you can specify which buffer to read from and generate a texture from the data.

However this is the slowest way to do it. there’s papers on nividia’s website about faster ways like glCopySubTexImage (or something like that - it’s early) - look for a paper called “render to texture”.

cheers

Allan