From: Ian Romanick Date: Thu, 12 Nov 2015 00:35:05 +0000 (-0800) Subject: i965/meta: Use internal functions for renderbuffer access X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=03506c9ef1c533bafde01b793571799d3ab52bf5;p=mesa.git i965/meta: Use internal functions for renderbuffer access Signed-off-by: Ian Romanick Reviewed-by: Anuj Phogat --- diff --git a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c b/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c index 51dbd000b1d..38a505ae10d 100644 --- a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c +++ b/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c @@ -857,9 +857,8 @@ brw_meta_resolve_color(struct brw_context *brw, rb = brw_get_rb_for_slice(brw, mt, 0, 0, false); _mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbo); - _mesa_FramebufferRenderbuffer(GL_DRAW_FRAMEBUFFER, - GL_COLOR_ATTACHMENT0, - GL_RENDERBUFFER, rb->Name); + _mesa_framebuffer_renderbuffer(ctx, ctx->DrawBuffer, GL_COLOR_ATTACHMENT0, + rb); _mesa_DrawBuffer(GL_COLOR_ATTACHMENT0); brw_fast_clear_init(brw); diff --git a/src/mesa/drivers/dri/i965/brw_meta_stencil_blit.c b/src/mesa/drivers/dri/i965/brw_meta_stencil_blit.c index 4f3f7dbc78c..16412ad3c04 100644 --- a/src/mesa/drivers/dri/i965/brw_meta_stencil_blit.c +++ b/src/mesa/drivers/dri/i965/brw_meta_stencil_blit.c @@ -442,8 +442,8 @@ brw_meta_stencil_blit(struct brw_context *brw, adjust_tiling(&dims, dst_mt->num_samples); _mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbo); - _mesa_FramebufferRenderbuffer(GL_DRAW_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, - GL_RENDERBUFFER, rb->Name); + _mesa_framebuffer_renderbuffer(ctx, ctx->DrawBuffer, GL_COLOR_ATTACHMENT0, + rb); _mesa_DrawBuffer(GL_COLOR_ATTACHMENT0); ctx->DrawBuffer->_Status = GL_FRAMEBUFFER_COMPLETE; @@ -546,8 +546,8 @@ brw_meta_stencil_updownsample(struct brw_context *brw, rb = brw_get_rb_for_slice(brw, src, 0, 0, false); _mesa_BindFramebuffer(GL_READ_FRAMEBUFFER, fbo); - _mesa_FramebufferRenderbuffer(GL_READ_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, - GL_RENDERBUFFER, rb->Name); + _mesa_framebuffer_renderbuffer(ctx, ctx->ReadBuffer, GL_STENCIL_ATTACHMENT, + rb); brw_meta_stencil_blit(brw, dst, 0, 0, &dims); brw_emit_mi_flush(brw); diff --git a/src/mesa/drivers/dri/i965/brw_meta_updownsample.c b/src/mesa/drivers/dri/i965/brw_meta_updownsample.c index c1631aeb0b5..149f4bcc810 100644 --- a/src/mesa/drivers/dri/i965/brw_meta_updownsample.c +++ b/src/mesa/drivers/dri/i965/brw_meta_updownsample.c @@ -127,13 +127,11 @@ brw_meta_updownsample(struct brw_context *brw, dst_fbo = fbos[1]; _mesa_BindFramebuffer(GL_READ_FRAMEBUFFER, src_fbo); - _mesa_FramebufferRenderbuffer(GL_READ_FRAMEBUFFER, attachment, - GL_RENDERBUFFER, src_rb->Name); + _mesa_framebuffer_renderbuffer(ctx, ctx->ReadBuffer, attachment, src_rb); _mesa_ReadBuffer(drawbuffer); _mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, dst_fbo); - _mesa_FramebufferRenderbuffer(GL_DRAW_FRAMEBUFFER, attachment, - GL_RENDERBUFFER, dst_rb->Name); + _mesa_framebuffer_renderbuffer(ctx, ctx->DrawBuffer, attachment, dst_rb); _mesa_DrawBuffer(drawbuffer); _mesa_BlitFramebuffer(0, 0,