summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2012-07-07 23:06:15 +0200
committerMarek Olšák <[email protected]>2012-07-12 02:08:30 +0200
commita730838a42c62b7729691b518a134017ff2d3b42 (patch)
treed4d7afbbd08a3739d3194c3150a5b754b9d40c9b /src/gallium
parent91cf9fe98838f35ea939ae9e44af87410f60fae9 (diff)
gallium/u_blitter: minify depth0 when initializing last_layer
Reviewed-by: Alex Deucher <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/auxiliary/util/u_blitter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_blitter.c b/src/gallium/auxiliary/util/u_blitter.c
index 47d0227a96d..99bde548e57 100644
--- a/src/gallium/auxiliary/util/u_blitter.c
+++ b/src/gallium/auxiliary/util/u_blitter.c
@@ -892,7 +892,7 @@ void util_blitter_default_src_texture(struct pipe_sampler_view *src_templ,
src_templ->u.tex.last_level = srclevel;
src_templ->u.tex.first_layer = 0;
src_templ->u.tex.last_layer =
- src->target == PIPE_TEXTURE_3D ? src->depth0 - 1
+ src->target == PIPE_TEXTURE_3D ? u_minify(src->depth0, srclevel) - 1
: src->array_size - 1;
src_templ->swizzle_r = PIPE_SWIZZLE_RED;
src_templ->swizzle_g = PIPE_SWIZZLE_GREEN;