<div class="gmail_quote">On Mon, Mar 7, 2011 at 11:16 PM, Brian Paul <span dir="ltr"><<a href="mailto:brianp@vmware.com">brianp@vmware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">On 03/07/2011 02:46 PM, Ian Romanick wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
-----BEGIN PGP SIGNED MESSAGE-----<br>
Hash: SHA1<br>
<br>
On 03/07/2011 07:16 AM, Brian Paul wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
On 03/05/2011 09:26 PM, Marek Olšák wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
RenderTexture doesn't have to be called in invalidate_rb, I guess.<br>
---<br>
</blockquote>
<br>
The patch looks good but there's one simple optimization that could be<br>
made. If glRenderBufferStorage() is called with a new width/height but<br>
the internalFormat stays the same, we wouldn't have to invalidate the<br>
parent FBO(s).<br>
<br>
I think changing the size of a renderbuffer would be more common than<br>
channging its format.<br>
</blockquote>
<br>
That's only true if the driver supports ARB_fbo. With EXT_fbo a<br>
framebuffer is incomplete if the attachments have mismatched sizes.<br>
This is one of the error conditions that was removed in the ARB version.<br>
</blockquote>
<br></div>
Grrr, right. Even for GL_ARB_fbo we'll need to revalidate FBOs when renderbuffers are resized because we compute the FBO's width/height as the min of the attached renderbuffers.<br>
<br>
I'm a little concerned about the efficiency of walking over all FBOs whenever we change a renderbuffer like this. If it turns out to be a problem when there's many FBOs we may need to keep a list of parent FBOs for each renderbuffer.<br>
<br>
Marek, your first patch is probably what we should commit.<br></blockquote><div><br>Alright. <br></div></div><br>Marek<br>