Mesa (master): mesa: define _MESA_NEW_SEPARATE_SPECULAR

Brian Paul brianp at kemper.freedesktop.org
Mon Mar 12 18:22:57 UTC 2012


Module: Mesa
Branch: master
Commit: 5edd7b8c46bbbaa59a421aa2c082374fc7dc101f
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=5edd7b8c46bbbaa59a421aa2c082374fc7dc101f

Author: Brian Paul <brianp at vmware.com>
Date:   Sun Mar 11 18:31:32 2012 -0600

mesa: define _MESA_NEW_SEPARATE_SPECULAR

This will replace the soon-to-be-removed _DD_NEW_SEPARATE_SPECULAR flag.
Note: there's a similar composite _MESA_NEW_NEED_EYE_COORDS flag set already.

Reviewed-by: José Fonseca <jfonseca at vmware.com>
Reviewed-by: Eric Anholt <eric at anholt.net>

---

 src/mesa/main/mtypes.h |    6 ++++++
 src/mesa/main/state.c  |    4 ++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 9b88f99..9b53da4 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -3117,6 +3117,12 @@ struct gl_matrix_stack
                                            _NEW_POINT |		\
                                            _NEW_PROGRAM |	\
                                            _NEW_MODELVIEW)
+
+#define _MESA_NEW_SEPARATE_SPECULAR        (_NEW_LIGHT | \
+                                            _NEW_FOG | \
+                                            _NEW_PROGRAM)
+
+
 /*@}*/
 
 
diff --git a/src/mesa/main/state.c b/src/mesa/main/state.c
index 20fd17d..0334f6f 100644
--- a/src/mesa/main/state.c
+++ b/src/mesa/main/state.c
@@ -534,7 +534,7 @@ _mesa_update_state_locked( struct gl_context *ctx )
    if (new_state & _NEW_PIXEL)
       _mesa_update_pixel( ctx, new_state );
 
-   if (new_state & _DD_NEW_SEPARATE_SPECULAR)
+   if (new_state & _MESA_NEW_SEPARATE_SPECULAR)
       update_separate_specular( ctx );
 
    if (new_state & (_NEW_BUFFERS | _NEW_VIEWPORT))
@@ -551,7 +551,7 @@ _mesa_update_state_locked( struct gl_context *ctx )
 
 #if 0
    if (new_state & (_NEW_POINT | _NEW_LINE | _NEW_POLYGON | _NEW_LIGHT
-                    | _NEW_STENCIL | _DD_NEW_SEPARATE_SPECULAR))
+                    | _NEW_STENCIL | _MESA_NEW_SEPARATE_SPECULAR))
       update_tricaps( ctx, new_state );
 #endif
 




More information about the mesa-commit mailing list