I've been writing a program based on the ScreenSnapshot example from apple: http://developer.apple.com/library/mac/#samplecode/OpenGLScreenSnapshot/Introduction/Intro.html and after upgrading from Snow Leopard to Lion my program stopped working. When I checked the example I realized it is not working either. For some reason glReadPixels function raises the GL_INVALID_FRAMEBUFFER_OPERATION_EXT error (0x0506).
I have reinstalled developer's tools but no luck. Has anyone made any progress with this issue? Any pointers will be greatly appreciated.