![]() ![]() If you used that method outlined above, which relies on uninitialized memory containing the desired content, on a compositing window system, the results will vary wildly, between solid clear color, over wildly distorted junk fragments, to data noise. With compositing each window has its own off-screen framebuffer and the screen's contents are composited only at the end. Today window compositing has become the norm which makes abusing OpenGL for taking screenshots almost impossible. ![]() If a OpenGL context is created on top of this, the framebuffer could be read out using glReadPixels, that way creating a screenshot. That OpenGL could be abused was due to the way graphics system did manage their on-screen windows' framebuffers: After a window without predefined background color/brush was created, its initial framebuffer content was simply everything that was on the screen right before the window's creation. OpenGL is primarily a drawing API and the contents of the main framebuffer are undefined unless it's drawn to by OpenGL functions themself. How can I capture the screen with … and OpenGL? ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |