Mesa (master): llvmpipe: fix swizzling of texture border color
Brian Paul
brianp at kemper.freedesktop.org
Mon Sep 27 21:07:20 UTC 2010
Module: Mesa
Branch: master
Commit: 3446af01798bd4bfcdb68f984a3ecd8f7ff9a4a4
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=3446af01798bd4bfcdb68f984a3ecd8f7ff9a4a4
Author: Brian Paul <brianp at vmware.com>
Date: Mon Sep 27 15:00:22 2010 -0600
llvmpipe: fix swizzling of texture border color
The pipe_sampler_view's swizzle terms also apply to the texture border
color. Simply move the apply_sampler_swizzle() call after we fetch
the border color.
Fixes many piglit texwrap failures.
---
src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
index f53ad91..33740f9 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c
@@ -171,8 +171,6 @@ lp_build_sample_texel_soa(struct lp_build_sample_context *bld,
i, j,
texel_out);
- apply_sampler_swizzle(bld, texel_out);
-
/*
* Note: if we find an app which frequently samples the texture border
* we might want to implement a true conditional here to avoid sampling
@@ -204,6 +202,8 @@ lp_build_sample_texel_soa(struct lp_build_sample_context *bld,
border_chan_vec, texel_out[chan]);
}
}
+
+ apply_sampler_swizzle(bld, texel_out);
}
More information about the mesa-commit
mailing list