openframeworks/openFrameworks — pull request #1908 by mcforman (2013-03-03 16:49:46+00:00)
Title: Fix iOS antialiased screen grab (#822).

Post-draw GL read-backs now work from antialiased framebuffer, to fix iOS screen grab issues such as with ofxiPhoneScreenGrab() and ofTexture::loadScreenData() (fix #822).

Done by setting display-mapped 'resolve' buffer (defaultFramebuffer) as the current framebuffer after a draw, rather than the fsaa buffer. The fsaa buffer is set as current again before next draw.

This means that any direct GL drawing code executed between update()+draw() cycles won't work, as it'll end up in the wrong framebuffer. *However*, I understand nobody should be doing that - if I'm wrong, well, dump it all!

Tested via ofxiPhoneScreenGrab() on an iPad2 and iPod Touch.