[Interest] Using PixelBufferObject to async copy from GPU to CPU

Nuno Santos nuno.santos at imaginando.pt
Wed Nov 20 15:20:39 CET 2024


Hi,

I’m trying to optimize an offscreen rendering in my application. I currently rely on glReadPixels to get the rendered image but in its more direct form is a blocking call. 

I want to take advantage of PBO to make this copy asynchronous and take less time to render the scene.

However, when trying to glMapBufferRange I always get a null ptr and if I check the GL error code I have “Invalid operation”:

You can have a look at the code here -> https://pastebin.com/KNKZgeQ0

I’m on Qt 6.8.0 and I’m still using OpenGL because I’m really stick to it on this application.

Is anyone using PBO’s to async copy from GPU to CPU from a framebuffer with Qt?

Thanks in advance!

Nuno
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20241120/142257c0/attachment.htm>


More information about the Interest mailing list