X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fgallium%2Fdrivers%2Fllvmpipe%2Flp_bld_interp.h;h=1b9ef5e878cc5eec053f0090ade49008d86e63a5;hb=e4ca1d64565b4d665bcaf5d08922bfbe1d920e7a;hp=5f72b0b895320a2efafe7ca773e3704ae4e868f8;hpb=6b63e25b3d7a6ac0bd738c139ead0c7e7ad84368;p=mesa.git diff --git a/src/gallium/drivers/llvmpipe/lp_bld_interp.h b/src/gallium/drivers/llvmpipe/lp_bld_interp.h index 5f72b0b8953..1b9ef5e878c 100644 --- a/src/gallium/drivers/llvmpipe/lp_bld_interp.h +++ b/src/gallium/drivers/llvmpipe/lp_bld_interp.h @@ -55,7 +55,7 @@ * src_index. * * LP_INTERP_COLOR is translated to either LP_INTERP_CONSTANT or - * LINEAR depending on flatshade state. + * PERSPECTIVE depending on flatshade state. */ enum lp_interp { LP_INTERP_CONSTANT, @@ -67,9 +67,11 @@ enum lp_interp { }; struct lp_shader_input { - ushort interp:4; /* enum lp_interp */ - ushort usage_mask:4; /* bitmask of TGSI_WRITEMASK_x flags */ - ushort src_index:8; /* where to find values in incoming vertices */ + uint interp:4; /* enum lp_interp */ + uint usage_mask:4; /* bitmask of TGSI_WRITEMASK_x flags */ + uint src_index:8; /* where to find values in incoming vertices */ + uint cyl_wrap:4; /* TGSI_CYLINDRICAL_WRAP_x flags */ + uint padding:12; }; @@ -77,21 +79,30 @@ struct lp_build_interp_soa_context { /* TGSI_QUAD_SIZE x float */ struct lp_build_context coeff_bld; + struct lp_build_context setup_bld; unsigned num_attribs; unsigned mask[1 + PIPE_MAX_SHADER_INPUTS]; /**< TGSI_WRITE_MASK_x */ enum lp_interp interp[1 + PIPE_MAX_SHADER_INPUTS]; + boolean simple_interp; + boolean depth_clamp; + + double pos_offset; LLVMValueRef x; LLVMValueRef y; - LLVMValueRef a [1 + PIPE_MAX_SHADER_INPUTS][TGSI_NUM_CHANNELS]; + LLVMValueRef a[1 + PIPE_MAX_SHADER_INPUTS][TGSI_NUM_CHANNELS]; LLVMValueRef dadq[1 + PIPE_MAX_SHADER_INPUTS][TGSI_NUM_CHANNELS]; - - LLVMValueRef oow; + LLVMValueRef a0aos[1 + PIPE_MAX_SHADER_INPUTS]; + LLVMValueRef dadxaos[1 + PIPE_MAX_SHADER_INPUTS]; + LLVMValueRef dadyaos[1 + PIPE_MAX_SHADER_INPUTS]; LLVMValueRef attribs[1 + PIPE_MAX_SHADER_INPUTS][TGSI_NUM_CHANNELS]; + LLVMValueRef xoffset_store; + LLVMValueRef yoffset_store; + /* * Convenience pointers. Callers may access this one. */ @@ -105,6 +116,8 @@ lp_build_interp_soa_init(struct lp_build_interp_soa_context *bld, struct gallivm_state *gallivm, unsigned num_inputs, const struct lp_shader_input *inputs, + boolean pixel_center_integer, + boolean depth_clamp, LLVMBuilderRef builder, struct lp_type type, LLVMValueRef a0_ptr, @@ -114,14 +127,13 @@ lp_build_interp_soa_init(struct lp_build_interp_soa_context *bld, LLVMValueRef y); void -lp_build_interp_soa_update_inputs(struct lp_build_interp_soa_context *bld, - struct gallivm_state *gallivm, - int quad_index); +lp_build_interp_soa_update_inputs_dyn(struct lp_build_interp_soa_context *bld, + struct gallivm_state *gallivm, + LLVMValueRef quad_start_index); void -lp_build_interp_soa_update_pos(struct lp_build_interp_soa_context *bld, - struct gallivm_state *gallivm, - int quad_index); - +lp_build_interp_soa_update_pos_dyn(struct lp_build_interp_soa_context *bld, + struct gallivm_state *gallivm, + LLVMValueRef quad_start_index); #endif /* LP_BLD_INTERP_H */