summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/state_tracker/st_atom_texture.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_atom_texture.c b/src/mesa/state_tracker/st_atom_texture.c
index a6135333b3e..19df6622ef1 100644
--- a/src/mesa/state_tracker/st_atom_texture.c
+++ b/src/mesa/state_tracker/st_atom_texture.c
@@ -59,6 +59,11 @@ swizzle_swizzle(unsigned swizzle1, unsigned swizzle2)
{
unsigned i, swz[4];
+ if (swizzle1 == SWIZZLE_XYZW) {
+ /* identity swizzle, no change to swizzle2 */
+ return swizzle2;
+ }
+
for (i = 0; i < 4; i++) {
unsigned s = GET_SWZ(swizzle1, i);
switch (s) {