1
\$\begingroup\$

I want to save the result screen of the rendering and then apply another shader on that result, the typical way is to read the screen using glReadPixels and then buffer that image to gpu and then apply my effect, so is there a way to bind the screen result to a texture id directory in gpu, instead of retrieving it back to CPU and then buffer it to GPU ?

\$\endgroup\$

1 Answer 1

0
\$\begingroup\$

Check out this great tutorial.

Basically you need to create a new texture of the size you want, and then use glDrawBuffers.

\$\endgroup\$
1
  • \$\begingroup\$ yes this is what i was looking for thanks a lot. \$\endgroup\$
    – Bahi Ali
    Sep 29, 2020 at 15:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .