The same as the patches I sent earlier, but as a single unified file.

For those that didn't read the original posting: This patch enables
GL_ARB_vertex_program support for the r200 driver. The vertex programs
are executed in software, but since this only replaces tcl everything
from the perspective divide onward is still hardware accelerated, even
when a vertex program is active.

Philipp Klaus Krause
Gemeinsame Unterverzeichnisse: r200.bak/CVS und r200/CVS.
diff -u r200.bak/r200_context.c r200/r200_context.c
--- r200.bak/r200_context.c	2004-08-19 18:20:48 +0200
+++ r200/r200_context.c	2004-08-19 18:44:23 +0200
@@ -62,7 +62,7 @@
 #include "r200_vtxfmt.h"
 #include "r200_maos.h"
 
-#define DRIVER_DATE	"20030328"
+#define DRIVER_DATE	"20040819"
 
 #include "vblank.h"
 #include "utils.h"
@@ -129,6 +129,7 @@
     "GL_ARB_texture_env_dot3",
     "GL_ARB_texture_mirrored_repeat",
     "GL_ARB_vertex_buffer_object",
+    "GL_ARB_vertex_program",
     "GL_EXT_blend_minmax",
     "GL_EXT_blend_subtract",
     "GL_EXT_secondary_color",
@@ -166,6 +167,7 @@
    &_tnl_fog_coordinate_stage,
    &_tnl_texgen_stage,
    &_tnl_texture_transform_stage,
+   &_tnl_vertex_program_stage,
 
    /* Try again to go to tcl? 
     *     - no good for asymmetric-twoside (do with multipass)
diff -u r200.bak/r200_state.c r200/r200_state.c
--- r200.bak/r200_state.c	2004-08-19 18:22:28 +0200
+++ r200/r200_state.c	2004-08-19 18:28:04 +0200
@@ -2043,6 +2043,10 @@
       r200UpdateSpecular ( ctx );
       break;
 
+   case GL_VERTEX_PROGRAM_ARB:
+      TCL_FALLBACK(rmesa->glCtx, R200_TCL_FALLBACK_TCL_DISABLE, state);
+      break;
+
    default:
       return;
    }
diff -u r200.bak/r200_tcl.h r200/r200_tcl.h
--- r200.bak/r200_tcl.h	2004-08-19 18:24:38 +0200
+++ r200/r200_tcl.h	2004-08-19 18:25:24 +0200
@@ -60,6 +60,7 @@
 #define R200_TCL_FALLBACK_TEXGEN_5          0x200 /* texgen, unit 5 */
 #define R200_TCL_FALLBACK_TCL_DISABLE       0x400 /* user disable */
 #define R200_TCL_FALLBACK_BITMAP            0x800 /* draw bitmap with points */
+#define R200_TCL_FALLBACK_VERTEX_PROGRAM    0x1000/* vertex program active */
 
 #define TCL_FALLBACK( ctx, bit, mode )	r200TclFallback( ctx, bit, mode )
 
Gemeinsame Unterverzeichnisse: r200.bak/server und r200/server.

Reply via email to