meta: Use _mesa_CreateFramebuffers instead of _mesa_GenFramebuffers
This enables later patches that will stop calling _mesa_GenFramebuffers or _mesa_CreateFramebuffers which pollute the framebuffer namespace. For framebuffers, the Bind call is still necessary. sed -i -e 's/_mesa_GenFramebuffers/_mesa_CreateFramebuffers/' \ src/mesa/drivers/common/*.c Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
This commit is contained in:
@@ -2794,7 +2794,7 @@ copytexsubimage_using_blit_framebuffer(struct gl_context *ctx, GLuint dims,
|
||||
|
||||
_mesa_meta_begin(ctx, MESA_META_ALL & ~MESA_META_DRAW_BUFFERS);
|
||||
|
||||
_mesa_GenFramebuffers(1, &fbo);
|
||||
_mesa_CreateFramebuffers(1, &fbo);
|
||||
_mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbo);
|
||||
|
||||
if (rb->_BaseFormat == GL_DEPTH_STENCIL ||
|
||||
@@ -3054,7 +3054,7 @@ decompress_texture_image(struct gl_context *ctx,
|
||||
|
||||
decompress_fbo->rb->RefCount = 1;
|
||||
|
||||
_mesa_GenFramebuffers(1, &decompress_fbo->FBO);
|
||||
_mesa_CreateFramebuffers(1, &decompress_fbo->FBO);
|
||||
_mesa_BindFramebuffer(GL_FRAMEBUFFER_EXT, decompress_fbo->FBO);
|
||||
_mesa_framebuffer_renderbuffer(ctx, ctx->DrawBuffer, GL_COLOR_ATTACHMENT0,
|
||||
decompress_fbo->rb);
|
||||
@@ -3512,7 +3512,7 @@ cleartexsubimage_for_zoffset(struct gl_context *ctx,
|
||||
GLuint fbo;
|
||||
bool success;
|
||||
|
||||
_mesa_GenFramebuffers(1, &fbo);
|
||||
_mesa_CreateFramebuffers(1, &fbo);
|
||||
_mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbo);
|
||||
|
||||
switch(texImage->_BaseFormat) {
|
||||
|
@@ -210,7 +210,7 @@ _mesa_meta_CopyImageSubData_uncompressed(struct gl_context *ctx,
|
||||
/* We really only need to stash the bound framebuffers and scissor. */
|
||||
_mesa_meta_begin(ctx, MESA_META_SCISSOR);
|
||||
|
||||
_mesa_GenFramebuffers(2, fbos);
|
||||
_mesa_CreateFramebuffers(2, fbos);
|
||||
_mesa_BindFramebuffer(GL_READ_FRAMEBUFFER, fbos[0]);
|
||||
_mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbos[1]);
|
||||
|
||||
|
@@ -110,7 +110,7 @@ fallback_required(struct gl_context *ctx, GLenum target,
|
||||
* Test that we can actually render in the texture's format.
|
||||
*/
|
||||
if (!mipmap->FBO)
|
||||
_mesa_GenFramebuffers(1, &mipmap->FBO);
|
||||
_mesa_CreateFramebuffers(1, &mipmap->FBO);
|
||||
_mesa_BindFramebuffer(fbo_target, mipmap->FBO);
|
||||
|
||||
_mesa_meta_framebuffer_texture_image(ctx, ctx->DrawBuffer,
|
||||
|
@@ -225,7 +225,7 @@ _mesa_meta_pbo_TexSubImage(struct gl_context *ctx, GLuint dims,
|
||||
_mesa_meta_begin(ctx, ~(MESA_META_PIXEL_TRANSFER |
|
||||
MESA_META_PIXEL_STORE));
|
||||
|
||||
_mesa_GenFramebuffers(2, fbos);
|
||||
_mesa_CreateFramebuffers(2, fbos);
|
||||
_mesa_BindFramebuffer(GL_READ_FRAMEBUFFER, fbos[0]);
|
||||
_mesa_BindFramebuffer(GL_DRAW_FRAMEBUFFER, fbos[1]);
|
||||
|
||||
@@ -363,7 +363,7 @@ _mesa_meta_pbo_GetTexSubImage(struct gl_context *ctx, GLuint dims,
|
||||
if (ctx->Extensions.ARB_color_buffer_float)
|
||||
_mesa_ClampColor(GL_CLAMP_FRAGMENT_COLOR, GL_FALSE);
|
||||
|
||||
_mesa_GenFramebuffers(2, fbos);
|
||||
_mesa_CreateFramebuffers(2, fbos);
|
||||
|
||||
if (tex_image && tex_image->TexObject->Target == GL_TEXTURE_1D_ARRAY) {
|
||||
assert(depth == 1);
|
||||
|
Reference in New Issue
Block a user