summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/api_arrayelt.c31
-rw-r--r--src/mesa/main/arrayobj.c2
-rw-r--r--src/mesa/main/arrayobj.h12
-rw-r--r--src/mesa/main/mtypes.h2
4 files changed, 12 insertions, 35 deletions
diff --git a/src/mesa/main/api_arrayelt.c b/src/mesa/main/api_arrayelt.c
index d530001bc5e..20b8ff4d1c7 100644
--- a/src/mesa/main/api_arrayelt.c
+++ b/src/mesa/main/api_arrayelt.c
@@ -1528,31 +1528,24 @@ static void _ae_update_state( struct gl_context *ctx )
for (i = 1; i < VERT_ATTRIB_GENERIC_MAX; i++) { /* skip zero! */
struct gl_client_array *attribArray = &arrayObj->VertexAttrib[VERT_ATTRIB_GENERIC(i)];
if (attribArray->Enabled) {
+ GLint intOrNorm;
at->array = attribArray;
/* Note: we can't grab the _glapi_Dispatch->VertexAttrib1fvNV
* function pointer here (for float arrays) since the pointer may
* change from one execution of _ae_ArrayElement() to
* the next. Doing so caused UT to break.
*/
- if (ctx->VertexProgram._Enabled
- && ctx->VertexProgram.Current->IsNVProgram) {
- at->func = AttribFuncsNV[at->array->Normalized]
- [at->array->Size-1]
- [TYPE_IDX(at->array->Type)];
- }
- else {
- GLint intOrNorm;
- if (at->array->Integer)
- intOrNorm = 2;
- else if (at->array->Normalized)
- intOrNorm = 1;
- else
- intOrNorm = 0;
-
- at->func = AttribFuncsARB[intOrNorm]
- [at->array->Size-1]
- [TYPE_IDX(at->array->Type)];
- }
+ if (at->array->Integer)
+ intOrNorm = 2;
+ else if (at->array->Normalized)
+ intOrNorm = 1;
+ else
+ intOrNorm = 0;
+
+ at->func = AttribFuncsARB[intOrNorm]
+ [at->array->Size-1]
+ [TYPE_IDX(at->array->Type)];
+
at->index = i;
check_vbo(actx, at->array->BufferObj);
at++;
diff --git a/src/mesa/main/arrayobj.c b/src/mesa/main/arrayobj.c
index 9255559d533..5959260c27f 100644
--- a/src/mesa/main/arrayobj.c
+++ b/src/mesa/main/arrayobj.c
@@ -314,8 +314,6 @@ _mesa_update_array_object_max_element(struct gl_context *ctx,
if (!ctx->VertexProgram._Current ||
ctx->VertexProgram._Current == ctx->VertexProgram._TnlProgram) {
enabled = _mesa_array_object_get_enabled_ff(arrayObj);
- } else if (ctx->VertexProgram._Current->IsNVProgram) {
- enabled = _mesa_array_object_get_enabled_nv(arrayObj);
} else {
enabled = _mesa_array_object_get_enabled_arb(arrayObj);
}
diff --git a/src/mesa/main/arrayobj.h b/src/mesa/main/arrayobj.h
index 4f89064bb66..dfefec2a7a3 100644
--- a/src/mesa/main/arrayobj.h
+++ b/src/mesa/main/arrayobj.h
@@ -87,18 +87,6 @@ _mesa_array_object_get_enabled_ff(const struct gl_array_object *arrayObj)
return arrayObj->_Enabled & VERT_BIT_FF_ALL;
}
-/** Returns the bitmask of all enabled arrays in nv shader mode.
- *
- * In nv shader mode, the nv generic arrays take precedence over
- * the legacy arrays.
- */
-static inline GLbitfield64
-_mesa_array_object_get_enabled_nv(const struct gl_array_object *arrayObj)
-{
- GLbitfield64 enabled = arrayObj->_Enabled;
- return enabled & ~(VERT_BIT_FF_NVALIAS & (enabled >> VERT_ATTRIB_GENERIC0));
-}
-
/** Returns the bitmask of all enabled arrays in arb/glsl shader mode.
*
* In arb/glsl shader mode all the fixed function and the arb/glsl generic
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 2b9f7f3ed28..1b2cfca81ff 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -195,8 +195,6 @@ typedef enum
#define VERT_BIT_TEX(i) VERT_BIT(VERT_ATTRIB_TEX(i))
#define VERT_BIT_TEX_ALL \
BITFIELD64_RANGE(VERT_ATTRIB_TEX(0), VERT_ATTRIB_TEX_MAX)
-#define VERT_BIT_FF_NVALIAS \
- BITFIELD64_RANGE(VERT_ATTRIB_POS, VERT_ATTRIB_TEX(VERT_ATTRIB_TEX_MAX))
#define VERT_BIT_GENERIC_NV(i) VERT_BIT(VERT_ATTRIB_GENERIC_NV(i))
#define VERT_BIT_GENERIC_NV_ALL \