[Mesa-dev] [PATCH] swrast: Use integer value 1 for true

Tapani Pälli tapani.palli at intel.com
Mon Aug 25 06:23:42 PDT 2014


commit 4e64cfbb4 changed how gl_constant_value bool gets interpreted
with drivers, for swrast driver true should be 1.

Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=82978
---
 src/mesa/drivers/dri/swrast/swrast.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/mesa/drivers/dri/swrast/swrast.c b/src/mesa/drivers/dri/swrast/swrast.c
index e28991b..459e6e6 100644
--- a/src/mesa/drivers/dri/swrast/swrast.c
+++ b/src/mesa/drivers/dri/swrast/swrast.c
@@ -775,6 +775,9 @@ dri_create_context(gl_api api,
     /* do bounds checking to prevent segfaults and server crashes! */
     mesaCtx->Const.CheckArrayBounds = GL_TRUE;
 
+    /* Use integer value 1 for true. */
+    mesaCtx->Const.UniformBooleanTrue = 1;
+
     /* create module contexts */
     _swrast_CreateContext( mesaCtx );
     _vbo_CreateContext( mesaCtx );
-- 
1.9.3



More information about the mesa-dev mailing list