Rendering to an invisible buffer and reading the results

I wanted to know if it’s possible to render several objects to a scene and then read the pixel buffers to get color information, all this without creating an actual window. How do you specify pixel size for the scene rendered?

Perhaps it’s possible to create a pbuffer without a window (I can’t remember the details of pbuffers), but is there something really bad with creating a window and just hiding it from the user?

I’m implementing an algorithm and want to get help from the H/W to do some of the calculations, I dont want to mess with windows, I dont need to actually see the results

What I think I need to do is create a Bitmap, get the HDC to it and using WGL set it as the drawing context. Did anybody do this or have a sample of working with the wgl?

Originally posted by liors:
What I think I need to do is create a Bitmap, get the HDC to it and using WGL set it as the drawing context. Did anybody do this or have a sample of working with the wgl?

If you choose bitmap, you’re stuck with Microsoft GDI Generic implementation (outdated software implementation).