enable arb_vertex_program by default if drm is new enough. Do a fallback when it...
authorRoland Scheidegger <rscheidegger@gmx.ch>
Sat, 10 Jun 2006 00:51:54 +0000 (00:51 +0000)
committerRoland Scheidegger <rscheidegger@gmx.ch>
Sat, 10 Jun 2006 00:51:54 +0000 (00:51 +0000)
src/mesa/drivers/dri/r200/r200_context.c
src/mesa/drivers/dri/r200/r200_vertprog.c

index 3e41d863148cecefc8473678d9208de698c3f53f..0e85b9680ce749d0852048e83573a5ec2781f98f 100644 (file)
@@ -478,7 +478,8 @@ GLboolean r200CreateContext( const __GLcontextModes *glVisual,
    if (rmesa->r200Screen->drmSupportsBlendColor) {
        driInitExtensions( ctx, blend_extensions, GL_FALSE );
    }
-   if(driQueryOptionb(&rmesa->optionCache, "arb_vertex_program"))
+   if(rmesa->r200Screen->drmSupportsVertexProgram || 
+      driQueryOptionb(&rmesa->optionCache, "arb_vertex_program"))
       driInitSingleExtension( ctx, ARB_vp_extension );
    if(driQueryOptionb(&rmesa->optionCache, "nv_vertex_program"))
       driInitSingleExtension( ctx, NV_vp_extension );
index dfacdc88cc4e58b8811694e10d7b7a05d5e90629..615953b6100bb7d00e0861ae3c03f0d4fbcb27a6 100644 (file)
@@ -414,6 +414,11 @@ static GLboolean r200_translate_vertex_program(struct r200_vertex_program *vp)
       return GL_FALSE;
    }
 
+   if (mesa_vp->IsNVProgram) {
+   /* subtle differences in spec like guaranteed initialized regs could cause
+      headaches. Might want to remove the driconf option to enable it completely */
+      return GL_FALSE;
+   }
    /* Initial value should be last tmp reg that hw supports.
       Strangely enough r300 doesnt mind even though these would be out of range.
       Smart enough to realize that it doesnt need it? */