diff options
author | Brian Paul <brianp@vmware.com> | 2010-04-19 17:05:05 -0600 |
---|---|---|
committer | Brian Paul <brianp@vmware.com> | 2010-04-19 17:07:25 -0600 |
commit | f4071e55dba8c0f45f3a7f59135b34e5b81fdab8 (patch) | |
tree | 09145390a1500ea50a33ed8e7a1bdaea67d47278 /src/gallium/drivers/llvmpipe/lp_jit.h | |
parent | 2cad62475b8263472f6fbd541b5b8ec2a1d40e62 (diff) |
llvmpipe: get 3D texture image stride from an array rather than computing it
This fixes broken 3D texture indexing when the height of the 3D texture
was less than 64 (the tile size). It's simpler to pass this as an array
(as we do with the row stride) than to compute it on the fly.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_jit.h')
-rw-r--r-- | src/gallium/drivers/llvmpipe/lp_jit.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_jit.h b/src/gallium/drivers/llvmpipe/lp_jit.h index 3790a71eab..5d0268c68c 100644 --- a/src/gallium/drivers/llvmpipe/lp_jit.h +++ b/src/gallium/drivers/llvmpipe/lp_jit.h @@ -52,6 +52,7 @@ struct lp_jit_texture uint32_t depth; uint32_t last_level; uint32_t row_stride[LP_MAX_TEXTURE_LEVELS]; + uint32_t img_stride[LP_MAX_TEXTURE_LEVELS]; const void *data[LP_MAX_TEXTURE_LEVELS]; }; @@ -62,7 +63,9 @@ enum { LP_JIT_TEXTURE_DEPTH, LP_JIT_TEXTURE_LAST_LEVEL, LP_JIT_TEXTURE_ROW_STRIDE, - LP_JIT_TEXTURE_DATA + LP_JIT_TEXTURE_IMG_STRIDE, + LP_JIT_TEXTURE_DATA, + LP_JIT_TEXTURE_NUM_FIELDS /* number of fields above */ }; |