summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authornick <nick@fuel7.com>2014-04-23 08:18:00 -0600
committerBrian Paul <brianp@vmware.com>2014-04-24 08:16:00 -0600
commit15c92464df07c5c0bb23a007358c560faeab76a8 (patch)
treee0b876f996de13b96d9521c13c58a3bf897467ae /src/mesa
parent1527a545a4ebb825db02bba9c9e42a90c15326f6 (diff)
swrast: Fix vertex color in _swsetup_Translate()
Straightforward fix to properly load dest->color with color data, as opposed to position data as previously implemented. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=27499 Cc: "10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/swrast_setup/ss_context.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/swrast_setup/ss_context.c b/src/mesa/swrast_setup/ss_context.c
index 12a47358faf..0b3b9e4dfbe 100644
--- a/src/mesa/swrast_setup/ss_context.c
+++ b/src/mesa/swrast_setup/ss_context.c
@@ -287,7 +287,8 @@ _swsetup_Translate( struct gl_context *ctx, const void *vertex, SWvertex *dest )
_tnl_get_attr( ctx, vertex, _TNL_ATTRIB_COLOR0,
dest->attrib[VARYING_SLOT_COL0] );
- UNCLAMPED_FLOAT_TO_RGBA_CHAN( dest->color, tmp );
+
+ UNCLAMPED_FLOAT_TO_RGBA_CHAN(dest->color, dest->attrib[VARYING_SLOT_COL0]);
_tnl_get_attr( ctx, vertex, _TNL_ATTRIB_COLOR1,
dest->attrib[VARYING_SLOT_COL1]);