Mesa (main): mesa: remove NEW_COPY_TEX_STATE
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Nov 5 09:29:55 UTC 2021
Module: Mesa
Branch: main
Commit: 9b8bc712b2b0f60eb090a03b43156cd98146917c
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=9b8bc712b2b0f60eb090a03b43156cd98146917c
Author: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer at amd.com>
Date: Tue Nov 2 14:05:24 2021 +0100
mesa: remove NEW_COPY_TEX_STATE
Since _NEW_PIXEL isn't handled in _mesa_update_state anymore, we can
replace NEW_COPY_TEX_STATE by _NEW_BUFFERS.
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13596>
---
src/mesa/main/teximage.c | 13 +++----------
1 file changed, 3 insertions(+), 10 deletions(-)
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index acf6ee651a2..322839fa22c 100644
--- a/src/mesa/main/teximage.c
+++ b/src/mesa/main/teximage.c
@@ -58,13 +58,6 @@
#include "pbo.h"
-/**
- * State changes which we care about for glCopyTex[Sub]Image() calls.
- * In particular, we care about pixel transfer state and buffer state
- * (such as glReadBuffer to make sure we read from the right renderbuffer).
- */
-#define NEW_COPY_TEX_STATE (_NEW_BUFFERS | _NEW_PIXEL)
-
/**
* Returns a corresponding internal floating point format for a given base
* format as specifed by OES_texture_float. In case of GL_FLOAT, the internal
@@ -4271,7 +4264,7 @@ copy_texture_sub_image_err(struct gl_context *ctx, GLuint dims,
_mesa_update_pixel(ctx);
- if (ctx->NewState & NEW_COPY_TEX_STATE)
+ if (ctx->NewState & _NEW_BUFFERS)
_mesa_update_state(ctx);
if (copytexsubimage_error_check(ctx, dims, texObj, target, level,
@@ -4296,7 +4289,7 @@ copy_texture_sub_image_no_error(struct gl_context *ctx, GLuint dims,
_mesa_update_pixel(ctx);
- if (ctx->NewState & NEW_COPY_TEX_STATE)
+ if (ctx->NewState & _NEW_BUFFERS)
_mesa_update_state(ctx);
copy_texture_sub_image(ctx, dims, texObj, target, level, xoffset, yoffset,
@@ -4327,7 +4320,7 @@ copyteximage(struct gl_context *ctx, GLuint dims, struct gl_texture_object *texO
_mesa_update_pixel(ctx);
- if (ctx->NewState & NEW_COPY_TEX_STATE)
+ if (ctx->NewState & _NEW_BUFFERS)
_mesa_update_state(ctx);
if (!no_error) {
More information about the mesa-commit
mailing list