diff options
author | Roland Scheidegger <[email protected]> | 2012-11-12 20:35:04 +0100 |
---|---|---|
committer | Roland Scheidegger <[email protected]> | 2012-11-12 21:02:59 +0100 |
commit | 26097c4855b97ee6e362c19df11d51fb7fd42192 (patch) | |
tree | dbc5018aa4b3a2c2fb2e1e0464be4776610cc044 /src/gallium/auxiliary/draw/draw_context.c | |
parent | 8257bb963f0b21c0c35da479707b5cacbc1c2824 (diff) |
gallivm,draw,llvmpipe: use base ptr + mip offsets instead of mip pointers
This might have a slight overhead but handling mip offsets more like
the width (and image) strides should make some things easier (mip level
being just part of the offset calculation) later.
Reviewed-by: Brian Paul <[email protected]>
Reviewed-by: José Fonseca <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/draw/draw_context.c')
-rw-r--r-- | src/gallium/auxiliary/draw/draw_context.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/gallium/auxiliary/draw/draw_context.c b/src/gallium/auxiliary/draw/draw_context.c index 91dd2e1a20a..6980631b365 100644 --- a/src/gallium/auxiliary/draw/draw_context.c +++ b/src/gallium/auxiliary/draw/draw_context.c @@ -802,17 +802,19 @@ draw_set_mapped_texture(struct draw_context *draw, unsigned sampler_idx, uint32_t width, uint32_t height, uint32_t depth, uint32_t first_level, uint32_t last_level, + const void *base_ptr, uint32_t row_stride[PIPE_MAX_TEXTURE_LEVELS], uint32_t img_stride[PIPE_MAX_TEXTURE_LEVELS], - const void *data[PIPE_MAX_TEXTURE_LEVELS]) + uint32_t mip_offsets[PIPE_MAX_TEXTURE_LEVELS]) { if (shader_stage == PIPE_SHADER_VERTEX) { #ifdef HAVE_LLVM if (draw->llvm) draw_llvm_set_mapped_texture(draw, sampler_idx, - width, height, depth, first_level, last_level, - row_stride, img_stride, data); + width, height, depth, first_level, + last_level, base_ptr, + row_stride, img_stride, mip_offsets); #endif } } |