Sign in to follow this  

how to get o/p from GPGPU fbo color attachments

This topic is 3859 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have loads of shaders and about 10 textures for GPGPU. I use color attachments. After doing all the calculations I want to get the data back from the textures. The below is good as long as the texture is still attached the color attachment.
	glBindTexture(iTextureType,texId);
	glReadBuffer(GL_COLOR_ATTACHMENT0_EXT);
	glReadPixels(0, 0, itexSizeW, itexSizeH, GL_RGBA, GL_FLOAT, textureData);
But how can i get the texture data if the color attachments have been cleared ? Have I lost the data for good ? basically i want to simply do:
	glBindTexture(iTextureType,texId);
	glReadPixels(0, 0, itexSizeW, itexSizeH, GL_RGBA, GL_FLOAT, textureData);
cheers

Share this post


Link to post
Share on other sites

This topic is 3859 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this