i965: Fix tex_swizzle when depth mode is GL_RED

Change swizzle from (x000) to (x001).

Signed-off-by: Chad Versace <chad.versace@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Chad Versace 2011-03-12 17:49:41 -08:00 committed by Kenneth Graunke
parent 9ebb904bbd
commit b8a077cee0

View file

@ -379,9 +379,10 @@ static void brw_wm_populate_key( struct brw_context *brw,
} else if (t->DepthMode == GL_LUMINANCE) {
swizzles[3] = SWIZZLE_ONE;
} else if (t->DepthMode == GL_RED) {
/* See table 3.23 of the GL 3.0 spec. */
swizzles[1] = SWIZZLE_ZERO;
swizzles[2] = SWIZZLE_ZERO;
swizzles[3] = SWIZZLE_ZERO;
swizzles[3] = SWIZZLE_ONE;
}
}