mesa: Branch 'master'

Nicolai Hähnle nh at kemper.freedesktop.org
Mon Apr 2 19:01:48 UTC 2007


 src/mesa/tnl/t_vp_build.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)

New commits:
diff-tree dba21ed913da2222e3b55fc8ba724ca93acbabf1 (from 66d336808d3eb01eab42fb311b932bfe9f7c6b1c)
Author: Nicolai Haehnle <nhaehnle at gmail.com>
Date:   Mon Apr 2 20:59:51 2007 +0200

    Fix in t_vp_build: Missed necessary updates sometimes
    
    _mesa_update_state doesn't always reset VertexProgram._Current to NULL.
    This caused us to skip a necessary update of the fixed function vertex
    program sometimes.
    
    Change the logic such that we check for updates whenever the _Current
    program is either NULL or the program generated by t_vp_build.

diff --git a/src/mesa/tnl/t_vp_build.c b/src/mesa/tnl/t_vp_build.c
index 63c99ee..dff062a 100644
--- a/src/mesa/tnl/t_vp_build.c
+++ b/src/mesa/tnl/t_vp_build.c
@@ -1506,7 +1506,8 @@ void _tnl_UpdateFixedFunctionProgram( GL
    GLuint hash;
    const struct gl_vertex_program *prev = ctx->VertexProgram._Current;
 
-   if (!ctx->VertexProgram._Current) {
+   if (!ctx->VertexProgram._Current ||
+       ctx->VertexProgram._Current == ctx->VertexProgram._TnlProgram) {
       /* Grab all the relevent state and put it in a single structure:
        */
       key = make_state_key(ctx);



More information about the mesa-commit mailing list