[Mesa-dev] [PATCH 03/19] r200: Remove support for software-only NV_vertex_program.

Eric Anholt eric at anholt.net
Tue Oct 9 18:06:35 PDT 2012


It wasn't supported in hardware, and the comments in the code indicated no
known uses (similar to my experience on Intel) and a possible intent to remove
it.
---
 src/mesa/drivers/dri/common/xmlpool/t_options.h |    5 -----
 src/mesa/drivers/dri/r200/r200_context.c        |    3 ---
 src/mesa/drivers/dri/r200/r200_vertprog.c       |    6 ------
 src/mesa/drivers/dri/radeon/radeon_screen.c     |    5 +----
 4 files changed, 1 insertion(+), 18 deletions(-)

diff --git a/src/mesa/drivers/dri/common/xmlpool/t_options.h b/src/mesa/drivers/dri/common/xmlpool/t_options.h
index 2427aa7..e2d4aae 100644
--- a/src/mesa/drivers/dri/common/xmlpool/t_options.h
+++ b/src/mesa/drivers/dri/common/xmlpool/t_options.h
@@ -263,11 +263,6 @@ DRI_CONF_OPT_BEGIN(arb_vertex_program,bool,def) \
         DRI_CONF_DESC(en,gettext("Enable extension GL_ARB_vertex_program")) \
 DRI_CONF_OPT_END
 
-#define DRI_CONF_NV_VERTEX_PROGRAM(def) \
-DRI_CONF_OPT_BEGIN(nv_vertex_program,bool,def) \
-        DRI_CONF_DESC(en,gettext("Enable extension GL_NV_vertex_program")) \
-DRI_CONF_OPT_END
-
 #define DRI_CONF_ALWAYS_FLUSH_BATCH(def) \
 DRI_CONF_OPT_BEGIN(always_flush_batch,bool,def) \
         DRI_CONF_DESC(en,gettext("Enable flushing batchbuffer after each draw call")) \
diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c
index 42f38a7..677dc8d 100644
--- a/src/mesa/drivers/dri/r200/r200_context.c
+++ b/src/mesa/drivers/dri/r200/r200_context.c
@@ -422,9 +422,6 @@ GLboolean r200CreateContext( gl_api api,
    ctx->Extensions.ARB_vertex_program = true;
    ctx->Extensions.EXT_gpu_program_parameters = true;
 
-   ctx->Extensions.NV_vertex_program =
-      driQueryOptionb(&rmesa->radeon.optionCache, "nv_vertex_program");
-
    ctx->Extensions.ATI_fragment_shader = (ctx->Const.MaxTextureUnits == 6);
 
    ctx->Extensions.ARB_point_sprite = true;
diff --git a/src/mesa/drivers/dri/r200/r200_vertprog.c b/src/mesa/drivers/dri/r200/r200_vertprog.c
index d26affb..4dc5d56 100644
--- a/src/mesa/drivers/dri/r200/r200_vertprog.c
+++ b/src/mesa/drivers/dri/r200/r200_vertprog.c
@@ -443,11 +443,6 @@ static GLboolean r200_translate_vertex_program(struct gl_context *ctx, struct r2
       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? */
@@ -1264,7 +1259,6 @@ r200IsProgramNative(struct gl_context *ctx, GLenum target, struct gl_program *pr
    struct r200_vertex_program *vp = (void *)prog;
 
    switch(target){
-   case GL_VERTEX_STATE_PROGRAM_NV:
    case GL_VERTEX_PROGRAM_ARB:
       if (!vp->translated) {
 	 r200_translate_vertex_program(ctx, vp);
diff --git a/src/mesa/drivers/dri/radeon/radeon_screen.c b/src/mesa/drivers/dri/radeon/radeon_screen.c
index 7a637dd..52247a9 100644
--- a/src/mesa/drivers/dri/radeon/radeon_screen.c
+++ b/src/mesa/drivers/dri/radeon/radeon_screen.c
@@ -125,11 +125,8 @@ DRI_CONF_BEGIN
     DRI_CONF_SECTION_DEBUG
         DRI_CONF_NO_RAST(false)
     DRI_CONF_SECTION_END
-    DRI_CONF_SECTION_SOFTWARE
-        DRI_CONF_NV_VERTEX_PROGRAM(false)
-    DRI_CONF_SECTION_END
 DRI_CONF_END;
-static const GLuint __driNConfigOptions = 17;
+static const GLuint __driNConfigOptions = 16;
 
 #endif
 
-- 
1.7.10.4



More information about the mesa-dev mailing list