summaryrefslogtreecommitdiff
path: root/src/mesa/tnl/t_imm_fixup.c
diff options
context:
space:
mode:
authorKeith Whitwell <keith@tungstengraphics.com>2003-08-05 18:55:49 +0000
committerKeith Whitwell <keith@tungstengraphics.com>2003-08-05 18:55:49 +0000
commitff56908e09c0351179478deb19677cf56eec1f64 (patch)
treeca51e376173869a8cb44304a0105b237f1dafce9 /src/mesa/tnl/t_imm_fixup.c
parente6dea091c0a1fe9ad9720c07ddf7164e5fc45ac6 (diff)
Store material attributes in an Attrib[] style array. This is a
first step to reviving/rescuing the 'vtx' rework from the old mesa tree.
Diffstat (limited to 'src/mesa/tnl/t_imm_fixup.c')
-rw-r--r--src/mesa/tnl/t_imm_fixup.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/mesa/tnl/t_imm_fixup.c b/src/mesa/tnl/t_imm_fixup.c
index cf3aa2ed96..5f821e7343 100644
--- a/src/mesa/tnl/t_imm_fixup.c
+++ b/src/mesa/tnl/t_imm_fixup.c
@@ -292,9 +292,9 @@ _tnl_fixup_input( GLcontext *ctx, struct immediate *IM )
i++;
vulnerable &= ~IM->MaterialMask[i];
- _mesa_copy_material_pairs( IM->Material[i],
- ctx->Light.Material,
- vulnerable );
+ _mesa_copy_materials( &IM->Material[i],
+ &ctx->Light.Material,
+ vulnerable );
++i;
@@ -311,14 +311,14 @@ copy_material( struct immediate *next,
/* _mesa_debug(NULL, "%s\n", __FUNCTION__); */
if (next->Material == 0) {
- next->Material = (struct gl_material (*)[2])
- MALLOC( sizeof(struct gl_material) * IMM_SIZE * 2 );
+ next->Material = (struct gl_material *)
+ MALLOC( sizeof(struct gl_material) * IMM_SIZE );
next->MaterialMask = (GLuint *) MALLOC( sizeof(GLuint) * IMM_SIZE );
}
next->MaterialMask[dst] = prev->MaterialOrMask;
- MEMCPY(next->Material[dst], prev->Material[src],
- 2 * sizeof(struct gl_material));
+ MEMCPY(&next->Material[dst], &prev->Material[src],
+ sizeof(struct gl_material));
}
@@ -590,9 +590,9 @@ _tnl_fixup_compiled_cassette( GLcontext *ctx, struct immediate *IM )
i++;
vulnerable &= ~IM->MaterialMask[i];
- _mesa_copy_material_pairs( IM->Material[i],
- ctx->Light.Material,
- vulnerable );
+ _mesa_copy_materials( &IM->Material[i],
+ &ctx->Light.Material,
+ vulnerable );
++i;