diff options
author | Chad Versace <chad.versace@intel.com> | 2011-03-12 17:49:41 -0800 |
---|---|---|
committer | Kenneth Graunke <kenneth@whitecape.org> | 2011-03-14 13:03:50 -0700 |
commit | 1842b89f77bb7bd283b61e27cd69c643f2a60a22 (patch) | |
tree | 06112682f2a4f309e23da0beba831a72bff5e2f1 /src/mesa/drivers/dri/i965 | |
parent | e0cbb154f2cb62e3ae0354dc4f14185dbad2bef2 (diff) |
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>
Diffstat (limited to 'src/mesa/drivers/dri/i965')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_wm.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c index 390b3d6b7e..ca17e80c8d 100644 --- a/src/mesa/drivers/dri/i965/brw_wm.c +++ b/src/mesa/drivers/dri/i965/brw_wm.c @@ -377,9 +377,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; } } |