[Mesa-dev] [PATCH 11/13] mesa: Minor clean ups in set_env_mode
Ian Romanick
idr at freedesktop.org
Wed Aug 24 18:46:19 UTC 2016
From: Ian Romanick <ian.d.romanick at intel.com>
Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
---
src/mesa/main/texenv.c | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/src/mesa/main/texenv.c b/src/mesa/main/texenv.c
index ba22301..d709a7d 100644
--- a/src/mesa/main/texenv.c
+++ b/src/mesa/main/texenv.c
@@ -51,7 +51,7 @@ set_env_mode(struct gl_context *ctx,
struct gl_texture_unit *texUnit,
GLenum mode)
{
- GLboolean legal;
+ bool legal;
if (texUnit->EnvMode == mode)
return;
@@ -63,24 +63,23 @@ set_env_mode(struct gl_context *ctx,
case GL_REPLACE:
case GL_ADD:
case GL_COMBINE:
- legal = GL_TRUE;
+ legal = true;
break;
case GL_REPLACE_EXT:
mode = GL_REPLACE; /* GL_REPLACE_EXT != GL_REPLACE */
- legal = GL_TRUE;
+ legal = true;
break;
case GL_COMBINE4_NV:
legal = ctx->Extensions.NV_texture_env_combine4;
break;
default:
- legal = GL_FALSE;
+ legal = false;
}
if (legal) {
FLUSH_VERTICES(ctx, _NEW_TEXTURE);
texUnit->EnvMode = mode;
- }
- else {
+ } else {
TE_ERROR(GL_INVALID_ENUM, "glTexEnv(param=%s)", mode);
}
}
--
2.5.5
More information about the mesa-dev
mailing list