• Advertisement
Sign in to follow this  

Opengl 3+ rendering to a texture

This topic is 1740 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

If i want to render to a texture in opengl 3+ can i uses the same vertex shader and fragment shader that I use to handle other regular loaded textures or do i need to create a separate vertex shader and fragment shader just for the handling of the frambuffer texture?

 

 

 

 

Share this post


Link to post
Share on other sites
Advertisement

It shouldn't matter whether the texture was/is attached to a fbo at any point. Just don't render to a texture you are currently sampling from :)

Share this post


Link to post
Share on other sites

Yes, you can use same fragment and vertex shaders for your framebuffer texture as well as for your rendering you main scene objects/textures.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement