View Full Version : switching fbo rendering: fastest way ?
06-23-2006, 10:11 AM
What is the fastest:
-switching multiple FBO (with one texture for each) using glBindFramebufferEXT()
-switching associated texture (with only one FBO) using glFramebufferTexture2DEXT() ?
The result seems the same to me, but I wonder if one method has performance impact compared to the other..
06-23-2006, 05:02 PM
I don't think so, not a lot anyway.
Theoreticly they should be the same, but i could be horribly wrong.
06-23-2006, 07:08 PM
Use glBindFramebufferEXT. That's the reason why we have a model using objects. Each object contains a complete state that can be prevalidated to some degree. For current hardware the difference may be relatively small, but for future hardware I would expect the difference to be bigger. It may not be immediately obvious, but FBO is structured in a way that's somewhat similar to how DX10 handles render target states. Of course, if the bottleneck is rendering it probably won't matter.
06-24-2006, 10:44 AM
I use glBindFramebufferEXT because it's how the extension is meant to be used, just like you don't reload your texture objects content but bind different textures, you should use extensions in the spirit they are given. (And so the spirit in which the IHV will optimise their drivers.)
Well my 0.02€
06-25-2006, 02:23 AM
Ok, I was asking that because my render scheme is a ping-pong between 2 textures (more than 6 pass) and I didn't saw the needs for numerous FBO if I could just switch the texture binding of one. So I'll create 2 FBO and attach each one a texture, and switch FBO context during my ping-pong...
However another part of my rendering process need to write to different mipmap level.. This time I won't able to escape the texture switch inside the FBO.
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.