From 26c872c2a22f25ec95065a71770b19b6a9eb06c7 Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Fri, 25 Jan 2013 18:27:05 +0100 Subject: r600g: don't use radeon_surface_level::npix_x/y/z npix_x/y/z is wrong with NPOT textures, since it's always aligned to POT if the level is non-zero, so we can't use that. This fixes piglit/spec/EXT_texture_shared_exponent/fbo-generatemipmap-formats. --- src/gallium/drivers/r600/evergreen_state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/gallium/drivers/r600/evergreen_state.c') diff --git a/src/gallium/drivers/r600/evergreen_state.c b/src/gallium/drivers/r600/evergreen_state.c index 1d491535bd2..ac85fb43659 100644 --- a/src/gallium/drivers/r600/evergreen_state.c +++ b/src/gallium/drivers/r600/evergreen_state.c @@ -1090,7 +1090,7 @@ evergreen_create_sampler_view_custom(struct pipe_context *ctx, width = width0; height = height0; - depth = surflevel[0].npix_z; + depth = texture->depth0; pitch = surflevel[0].nblk_x * util_format_get_blockwidth(pipe_format); non_disp_tiling = tmp->non_disp_tiling; -- cgit v1.2.3