gallivm: fix indirect addressing of constant buffer
[mesa.git] / src / gallium / auxiliary / gallivm / lp_bld_tgsi.h
index 4ca730a98a07aef9da79a79e9f646f37e4a79a86..4d415b6d4161e0dbc06c11a72c807c1d5add6f1b 100644 (file)
@@ -45,9 +45,6 @@ struct lp_build_context;
 struct lp_build_mask_context;
 
 
-#define LP_BLD_SAMPLER_EXPLICIT_DERIVATIVES 1
-
-
 /**
  * Sampler code generation interface.
  *
@@ -62,7 +59,7 @@ struct lp_build_sampler_soa
    (*destroy)( struct lp_build_sampler_soa *sampler );
 
    void
-   (*emit_fetch_texel)( struct lp_build_sampler_soa *sampler,
+   (*emit_fetch_texel)( const struct lp_build_sampler_soa *sampler,
                         LLVMBuilderRef builder,
                         struct lp_type type,
                         unsigned unit,
@@ -70,7 +67,8 @@ struct lp_build_sampler_soa
                         const LLVMValueRef *coords,
                         const LLVMValueRef *ddx,
                         const LLVMValueRef *ddy,
-                        LLVMValueRef lodbias,
+                        LLVMValueRef lod_bias, /* optional */
+                        LLVMValueRef explicit_lod, /* optional */
                         LLVMValueRef *texel);
 };
 
@@ -85,7 +83,7 @@ lp_build_tgsi_soa(LLVMBuilderRef builder,
                   const LLVMValueRef (*inputs)[4],
                   LLVMValueRef (*outputs)[4],
                   struct lp_build_sampler_soa *sampler,
-                  struct tgsi_shader_info *info);
+                  const struct tgsi_shader_info *info);
 
 
 #endif /* LP_BLD_TGSI_H */