Updates for pipeline_stage struct changes.
authorKeith Whitwell <keith@tungstengraphics.com>
Fri, 22 Apr 2005 22:47:09 +0000 (22:47 +0000)
committerKeith Whitwell <keith@tungstengraphics.com>
Fri, 22 Apr 2005 22:47:09 +0000 (22:47 +0000)
src/mesa/drivers/windows/gldirect/dx7/gld_vb_d3d_render_dx7.c
src/mesa/drivers/windows/gldirect/dx7/gld_vb_mesa_render_dx7.c
src/mesa/drivers/windows/gldirect/dx8/gld_vb_d3d_render_dx8.c
src/mesa/drivers/windows/gldirect/dx8/gld_vb_mesa_render_dx8.c
src/mesa/drivers/windows/gldirect/dx9/gld_vb_d3d_render_dx9.c
src/mesa/drivers/windows/gldirect/dx9/gld_vb_mesa_render_dx9.c

index b2d7a853f4ff4cae01a622929bd1f3456a6e4c40..a85620dde8d2452a94d6467f2f443c49c385257e 100644 (file)
@@ -124,7 +124,6 @@ static GLboolean gld_d3d_render_stage_run(
 
        TNLcontext                              *tnl;
        struct vertex_buffer    *VB;
-       GLuint                                  new_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass;
        GLD_pb_dx7                              *gldPB = &gld->PB3d;
@@ -140,12 +139,11 @@ static GLboolean gld_d3d_render_stage_run(
        // but we'll test gld->bUseMesaTnL anyway.
        if (gld->bUseMesaTnL) {
                // Do nothing in this stage, but continue pipeline
-               return GL_FALSE;
+               return GL_TRUE;
        }
        
        tnl = TNL_CONTEXT(ctx);
        VB = &tnl->vb;
-       new_inputs = stage->changed_inputs;
        pass = 0;
 
    tnl->Driver.Render.Start( ctx );
@@ -243,45 +241,16 @@ static GLboolean gld_d3d_render_stage_run(
        return GL_FALSE;                /* finished the pipe */
 }
 
-//---------------------------------------------------------------------------
-
-static void gld_d3d_render_stage_check(
-       GLcontext *ctx,
-       struct tnl_pipeline_stage *stage)
-{
-       GLD_context                             *gldCtx = GLD_GET_CONTEXT(ctx);
-       GLD_driver_dx7                  *gld    = GLD_GET_DX7_DRIVER(gldCtx);
-       // Is this thread safe?
-       stage->active = (gld->bUseMesaTnL) ? GL_FALSE : GL_TRUE;
-       return;
-}
-
-//---------------------------------------------------------------------------
-
-static void gld_d3d_render_stage_dtr( struct tnl_pipeline_stage *stage )
-{
-}
 
 //---------------------------------------------------------------------------
 
 const struct tnl_pipeline_stage _gld_d3d_render_stage =
 {
    "gld_d3d_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          /* re-check (new inputs, interp function) */
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   gld_d3d_render_stage_dtr,           /* destructor */
-   gld_d3d_render_stage_check,         /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    gld_d3d_render_stage_run                    /* run */
 };
 
index 9035574045f3c2b66405d5a5d76c5f27b218a149..92226c5cc62534ee4692d535b3b8eaa0f4f689c4 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: gld_vb_mesa_render_dx7.c,v 1.4 2005/04/15 17:17:47 bencrossman Exp $ */
+/* $Id: gld_vb_mesa_render_dx7.c,v 1.5 2005/04/22 22:47:09 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
@@ -317,7 +317,6 @@ static GLboolean _gld_mesa_render_stage_run(
                
        TNLcontext                              *tnl = TNL_CONTEXT(ctx);
        struct vertex_buffer    *VB = &tnl->vb;
-       GLuint                                  new_inputs = stage->changed_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass = 0;
        GLD_pb_dx7                              *gldPB;
@@ -358,7 +357,7 @@ static GLboolean _gld_mesa_render_stage_run(
        ASSERT(tnl->Driver.Render.ClippedPolygon);
        ASSERT(tnl->Driver.Render.Finish);
        
-       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, new_inputs );
+       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, ~0 );
        
        if (VB->ClipOrMask) {
                tab = VB->Elts ? clip_render_tab_elts : clip_render_tab_verts;
@@ -413,44 +412,13 @@ static GLboolean _gld_mesa_render_stage_run(
 
 
 
-/* Quite a bit of work involved in finding out the inputs for the
- * render stage.
- */
-static void _gld_mesa_render_stage_check(
-       GLcontext *ctx,
-       struct tnl_pipeline_stage *stage)
-{
-   stage->inputs = TNL_CONTEXT(ctx)->render_inputs;
-}
-
-//---------------------------------------------------------------------------
-
-// Destructor
-static void _gld_mesa_render_stage_dtr(
-       struct tnl_pipeline_stage *stage)
-{
-}
-
-//---------------------------------------------------------------------------
-
 const struct tnl_pipeline_stage _gld_mesa_render_stage =
 {
    "gld_mesa_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          // re-check (new inputs, interp function)
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   _gld_mesa_render_stage_dtr,                         /* destructor */
-   _gld_mesa_render_stage_check,               /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    _gld_mesa_render_stage_run  /* run */
 };
 
index 0ae9d6c7e5a8237e1cc89d88dbc9fec1e24a494c..cafbf4f5c50a089bc8dfcaf5f2679484d4b347e5 100644 (file)
@@ -124,7 +124,6 @@ static GLboolean gld_d3d_render_stage_run(
 
        TNLcontext                              *tnl;
        struct vertex_buffer    *VB;
-       GLuint                                  new_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass;
        GLD_pb_dx8                              *gldPB = &gld->PB3d;
@@ -138,12 +137,11 @@ static GLboolean gld_d3d_render_stage_run(
        // but we'll test gld->bUseMesaTnL anyway.
        if (gld->bUseMesaTnL) {
                // Do nothing in this stage, but continue pipeline
-               return GL_FALSE;
+               return GL_TRUE;
        }
        
        tnl = TNL_CONTEXT(ctx);
        VB = &tnl->vb;
-       new_inputs = stage->changed_inputs;
        pass = 0;
 
    tnl->Driver.Render.Start( ctx );
@@ -238,43 +236,13 @@ static GLboolean gld_d3d_render_stage_run(
 
 //---------------------------------------------------------------------------
 
-static void gld_d3d_render_stage_check(
-       GLcontext *ctx,
-       struct tnl_pipeline_stage *stage)
-{
-       GLD_context                             *gldCtx = GLD_GET_CONTEXT(ctx);
-       GLD_driver_dx8                  *gld    = GLD_GET_DX8_DRIVER(gldCtx);
-       // Is this thread safe?
-       stage->active = (gld->bUseMesaTnL) ? GL_FALSE : GL_TRUE;
-       return;
-}
-
-//---------------------------------------------------------------------------
-
-static void gld_d3d_render_stage_dtr( struct tnl_pipeline_stage *stage )
-{
-}
-
-//---------------------------------------------------------------------------
-
 const struct tnl_pipeline_stage _gld_d3d_render_stage =
 {
    "gld_d3d_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          /* re-check (new inputs, interp function) */
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   gld_d3d_render_stage_dtr,           /* destructor */
-   gld_d3d_render_stage_check,         /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    gld_d3d_render_stage_run                    /* run */
 };
 
index c07370474a8a11c4417179941664a2c64ce5fed6..3c10f962812612fd5262f4b3f7e15cd0be70ceb0 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: gld_vb_mesa_render_dx8.c,v 1.4 2005/04/15 17:17:47 bencrossman Exp $ */
+/* $Id: gld_vb_mesa_render_dx8.c,v 1.5 2005/04/22 22:47:10 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
@@ -317,7 +317,6 @@ static GLboolean _gld_mesa_render_stage_run(
                
        TNLcontext                              *tnl = TNL_CONTEXT(ctx);
        struct vertex_buffer    *VB = &tnl->vb;
-       GLuint                                  new_inputs = stage->changed_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass = 0;
        GLD_pb_dx8                              *gldPB;
@@ -379,7 +378,7 @@ static GLboolean _gld_mesa_render_stage_run(
        ASSERT(tnl->Driver.Render.ClippedPolygon);
        ASSERT(tnl->Driver.Render.Finish);
        
-       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, new_inputs );
+       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, ~0 );
        
        if (VB->ClipOrMask) {
                tab = VB->Elts ? clip_render_tab_elts : clip_render_tab_verts;
@@ -436,44 +435,16 @@ static GLboolean _gld_mesa_render_stage_run(
 
 
 
-/* Quite a bit of work involved in finding out the inputs for the
- * render stage.
- */
-static void _gld_mesa_render_stage_check(
-       GLcontext *ctx,
-       struct tnl_pipeline_stage *stage)
-{
-   stage->inputs = TNL_CONTEXT(ctx)->render_inputs;
-}
-
-//---------------------------------------------------------------------------
-
-// Destructor
-static void _gld_mesa_render_stage_dtr(
-       struct tnl_pipeline_stage *stage)
-{
-}
 
 //---------------------------------------------------------------------------
 
 const struct tnl_pipeline_stage _gld_mesa_render_stage =
 {
    "gld_mesa_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          // re-check (new inputs, interp function)
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   _gld_mesa_render_stage_dtr,                         /* destructor */
-   _gld_mesa_render_stage_check,               /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    _gld_mesa_render_stage_run  /* run */
 };
 
index 9a55d352b20cb0e15161d5fc8aebbd226b8bb443..4fa6bcaf1abd1f9598ff271d969ffc78a750f5d4 100644 (file)
@@ -124,7 +124,6 @@ static GLboolean gld_d3d_render_stage_run(
 
        TNLcontext                              *tnl;
        struct vertex_buffer    *VB;
-       GLuint                                  new_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass;
        GLD_pb_dx9                              *gldPB = &gld->PB3d;
@@ -138,12 +137,11 @@ static GLboolean gld_d3d_render_stage_run(
        // but we'll test gld->bUseMesaTnL anyway.
        if (gld->bUseMesaTnL) {
                // Do nothing in this stage, but continue pipeline
-               return GL_FALSE;
+               return GL_TRUE;
        }
        
        tnl = TNL_CONTEXT(ctx);
        VB = &tnl->vb;
-       new_inputs = stage->changed_inputs;
        pass = 0;
 
    tnl->Driver.Render.Start( ctx );
@@ -249,32 +247,16 @@ static void gld_d3d_render_stage_check(
        return;
 }
 
-//---------------------------------------------------------------------------
-
-static void gld_d3d_render_stage_dtr( struct tnl_pipeline_stage *stage )
-{
-}
 
 //---------------------------------------------------------------------------
 
 const struct tnl_pipeline_stage _gld_d3d_render_stage =
 {
    "gld_d3d_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          /* re-check (new inputs, interp function) */
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   gld_d3d_render_stage_dtr,           /* destructor */
-   gld_d3d_render_stage_check,         /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    gld_d3d_render_stage_run                    /* run */
 };
 
index 1dff553a4a7d55de4701b4cb257ef3ae7fc8d327..d1b1b8b65ee7bb01688e4cf51f78172334333896 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: gld_vb_mesa_render_dx9.c,v 1.4 2005/04/15 17:17:47 bencrossman Exp $ */
+/* $Id: gld_vb_mesa_render_dx9.c,v 1.5 2005/04/22 22:47:10 keithw Exp $ */
 
 /*
  * Mesa 3-D graphics library
@@ -312,7 +312,6 @@ static GLboolean _gld_mesa_render_stage_run(
                
        TNLcontext                              *tnl = TNL_CONTEXT(ctx);
        struct vertex_buffer    *VB = &tnl->vb;
-       GLuint                                  new_inputs = stage->changed_inputs;
        tnl_render_func                         *tab;
        GLint                                   pass = 0;
        GLD_pb_dx9                              *gldPB;
@@ -376,7 +375,7 @@ static GLboolean _gld_mesa_render_stage_run(
        ASSERT(tnl->Driver.Render.ClippedPolygon);
        ASSERT(tnl->Driver.Render.Finish);
        
-       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, new_inputs );
+       tnl->Driver.Render.BuildVertices( ctx, 0, VB->Count, ~0 );
        
        if (VB->ClipOrMask) {
                tab = VB->Elts ? clip_render_tab_elts : clip_render_tab_verts;
@@ -433,44 +432,14 @@ static GLboolean _gld_mesa_render_stage_run(
 
 
 
-/* Quite a bit of work involved in finding out the inputs for the
- * render stage.
- */
-static void _gld_mesa_render_stage_check(
-       GLcontext *ctx,
-       struct tnl_pipeline_stage *stage)
-{
-   stage->inputs = TNL_CONTEXT(ctx)->render_inputs;
-}
-
-//---------------------------------------------------------------------------
-
-// Destructor
-static void _gld_mesa_render_stage_dtr(
-       struct tnl_pipeline_stage *stage)
-{
-}
-
-//---------------------------------------------------------------------------
 
 const struct tnl_pipeline_stage _gld_mesa_render_stage =
 {
    "gld_mesa_render_stage",
-   (_NEW_BUFFERS |
-    _DD_NEW_SEPARATE_SPECULAR |
-    _DD_NEW_FLATSHADE |
-    _NEW_TEXTURE|
-    _NEW_LIGHT|
-    _NEW_POINT|
-    _NEW_FOG|
-    _DD_NEW_TRI_UNFILLED |
-    _NEW_RENDERMODE),          // re-check (new inputs, interp function)
-   0,                          /* re-run (always runs) */
-   GL_TRUE,                    /* active */
-   0, 0,                       /* inputs (set in check_render), outputs */
-   0, 0,                       /* changed_inputs, private */
-   _gld_mesa_render_stage_dtr,                         /* destructor */
-   _gld_mesa_render_stage_check,               /* check */
+   NULL,
+   NULL,
+   NULL,
+   NULL,
    _gld_mesa_render_stage_run  /* run */
 };