Closed codeanticode closed 11 years ago
We do this in the Quartz Composer plugin, using glCopyTexImage2D to get the current read buffer's content into a texture. Something similar should be possible with direct to context drawing, no?
https://github.com/Syphon/Quartz-Composer/blob/master/SyphonQC/SyphonQC/SyphonServerQCPlugIn.m#L223
(note that code incorrectly assumes GL_FRONT is the right read buffer but, fwiw, the technique is sound)
Yes I agree, thanks for the link, I will try to add this functionality for the 1.0 release.
Right now, the frames sent out from Processing when using the SyphonServer object need to be drawn to an offscreen PGraphics buffer. It would be neat to just be able to do:
This requires the server object getting the internal back buffer that the renderer uses to draw the main screen to. It is certainly possible, since this is what the filter(PShader) method does under the scenes.
[ported from issue report in googlecode: https://code.google.com/p/syphon-implementations/issues/detail?id=27]