fix up radeon span functions using latest r200 code from Brian,
[mesa.git] / src / mesa / drivers / dri / i915 / intel_context.c
index d30136a7d5d39e0119d319a1996b7cdbaff1a52f..d39e45d0b33b4497d7890e7fdbf52d65fa5dbeb9 100644 (file)
@@ -153,7 +153,7 @@ static void intelBufferSize(GLframebuffer *buffer,
  * It appears that ARB_texture_env_crossbar has "disappeared" compared to the
  * old i830-specific driver.
  */
-static const struct dri_extension card_extensions[] =
+const struct dri_extension card_extensions[] =
 {
     { "GL_ARB_multisample",                GL_ARB_multisample_functions },
     { "GL_ARB_multitexture",               NULL },
@@ -206,6 +206,7 @@ static const struct tnl_pipeline_stage *intel_pipeline[] = {
    &_tnl_texgen_stage,
    &_tnl_texture_transform_stage,
    &_tnl_point_attenuation_stage,
+   &_tnl_arb_vertex_program_stage,
    &_tnl_vertex_program_stage,
 #if 1
    &_intel_render_stage,     /* ADD: unclipped rastersetup-to-dma */
@@ -696,15 +697,24 @@ void intelInitState( GLcontext *ctx )
    ctx->Driver.Scissor( ctx, ctx->Scissor.X, ctx->Scissor.Y,
                        ctx->Scissor.Width, ctx->Scissor.Height );
    ctx->Driver.ShadeModel( ctx, ctx->Light.ShadeModel );
-   ctx->Driver.StencilFunc( ctx, 
-                           ctx->Stencil.Function[0],
-                           ctx->Stencil.Ref[0],
-                           ctx->Stencil.ValueMask[0] );
-   ctx->Driver.StencilMask( ctx, ctx->Stencil.WriteMask[0] );
-   ctx->Driver.StencilOp( ctx, 
-                         ctx->Stencil.FailFunc[0],
-                         ctx->Stencil.ZFailFunc[0],
-                         ctx->Stencil.ZPassFunc[0]);
+   ctx->Driver.StencilFuncSeparate( ctx, GL_FRONT,
+                                    ctx->Stencil.Function[0],
+                                    ctx->Stencil.Ref[0],
+                                    ctx->Stencil.ValueMask[0] );
+   ctx->Driver.StencilFuncSeparate( ctx, GL_BACK,
+                                    ctx->Stencil.Function[1],
+                                    ctx->Stencil.Ref[1],
+                                    ctx->Stencil.ValueMask[1] );
+   ctx->Driver.StencilMaskSeparate( ctx, GL_FRONT, ctx->Stencil.WriteMask[0] );
+   ctx->Driver.StencilMaskSeparate( ctx, GL_BACK, ctx->Stencil.WriteMask[1] );
+   ctx->Driver.StencilOpSeparate( ctx, GL_FRONT,
+                                  ctx->Stencil.FailFunc[0],
+                                  ctx->Stencil.ZFailFunc[0],
+                                  ctx->Stencil.ZPassFunc[0]);
+   ctx->Driver.StencilOpSeparate( ctx, GL_BACK,
+                                  ctx->Stencil.FailFunc[1],
+                                  ctx->Stencil.ZFailFunc[1],
+                                  ctx->Stencil.ZPassFunc[1]);
 
 
    ctx->Driver.DrawBuffer( ctx, ctx->Color.DrawBuffer[0] );