diff options
author | José Fonseca <jfonseca@vmware.com> | 2010-10-09 09:34:31 +0100 |
---|---|---|
committer | José Fonseca <jfonseca@vmware.com> | 2010-10-09 09:34:31 +0100 |
commit | 34c11c87e4e3b5639764abee413c45e918749477 (patch) | |
tree | c77556cc81e756cb60d70319c2c245b92eed1e6d /src/gallium/auxiliary/gallivm/lp_bld_sample.h | |
parent | 6316d540564d116460bfd1382e3eee98480e28ff (diff) |
gallivm: Do size computations simultanously for all dimensions (AoS).
Operate simultanouesly on <width, height, depth> vector as much as possible,
instead of doing the operations on vectors with broadcasted scalars.
Also do the 24.8 fixed point scalar with integer shift of the texture size,
for unnormalized coordinates.
AoS path only for now -- the same thing can be done for SoA.
Diffstat (limited to 'src/gallium/auxiliary/gallivm/lp_bld_sample.h')
-rw-r--r-- | src/gallium/auxiliary/gallivm/lp_bld_sample.h | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_sample.h b/src/gallium/auxiliary/gallivm/lp_bld_sample.h index d1a1aa143d..ce2285446a 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_sample.h +++ b/src/gallium/auxiliary/gallivm/lp_bld_sample.h @@ -333,14 +333,30 @@ lp_build_get_const_mipmap_level(struct lp_build_sample_context *bld, void lp_build_mipmap_level_sizes(struct lp_build_sample_context *bld, LLVMValueRef ilevel, - LLVMValueRef *out_width_vec, - LLVMValueRef *out_height_vec, - LLVMValueRef *out_depth_vec, + LLVMValueRef *out_size_vec, LLVMValueRef *row_stride_vec, LLVMValueRef *img_stride_vec); void +lp_build_extract_image_sizes(struct lp_build_sample_context *bld, + struct lp_type size_type, + struct lp_type coord_type, + LLVMValueRef size, + LLVMValueRef *out_width, + LLVMValueRef *out_height, + LLVMValueRef *out_depth); + + +void +lp_build_unnormalized_coords(struct lp_build_sample_context *bld, + LLVMValueRef flt_size, + LLVMValueRef *s, + LLVMValueRef *t, + LLVMValueRef *r); + + +void lp_build_cube_lookup(struct lp_build_sample_context *bld, LLVMValueRef s, LLVMValueRef t, |