unsigned lod_bias_non_zero:1;
unsigned apply_min_lod:1; /**< min_lod > 0 ? */
unsigned apply_max_lod:1; /**< max_lod < last_level ? */
+ unsigned seamless_cube_map:1;
/* Hacks */
unsigned force_nearest_s:1;
/** SIMD vector width */
unsigned vector_width;
- /** number of lod values (valid are 1, length/4, length) */
+ /** number of mipmaps (valid are 1, length/4, length) */
+ unsigned num_mips;
+
+ /** number of lod values (valid are 1, length/4, length) */
unsigned num_lods;
/** regular scalar float type */
struct lp_type leveli_type;
struct lp_build_context leveli_bld;
+ /** Float lod type */
+ struct lp_type lodf_type;
+ struct lp_build_context lodf_bld;
+
+ /** Int lod type */
+ struct lp_type lodi_type;
+ struct lp_build_context lodi_bld;
+
/* Common dynamic state values */
LLVMValueRef row_stride_array;
LLVMValueRef img_stride_array;
LLVMValueRef explicit_lod, /* optional */
unsigned mip_filter,
LLVMValueRef *out_lod_ipart,
- LLVMValueRef *out_lod_fpart);
+ LLVMValueRef *out_lod_fpart,
+ LLVMValueRef *out_lod_positive);
void
lp_build_nearest_mip_level(struct lp_build_sample_context *bld,
void
lp_build_cube_lookup(struct lp_build_sample_context *bld,
LLVMValueRef *coords,
- const struct lp_derivatives *derivs, /* optional */
+ const struct lp_derivatives *derivs_in, /* optional */
LLVMValueRef *rho,
+ struct lp_derivatives *derivs_out, /* optional */
boolean need_derivs);
+void
+lp_build_cube_new_coords(struct lp_build_context *ivec_bld,
+ LLVMValueRef face,
+ LLVMValueRef x0,
+ LLVMValueRef x1,
+ LLVMValueRef y0,
+ LLVMValueRef y1,
+ LLVMValueRef max_coord,
+ LLVMValueRef new_faces[4],
+ LLVMValueRef new_xcoords[4][2],
+ LLVMValueRef new_ycoords[4][2]);
+
+
void
lp_build_sample_partial_offset(struct lp_build_context *bld,
unsigned block_length,
LLVMValueRef
lp_build_minify(struct lp_build_context *bld,
LLVMValueRef base_size,
- LLVMValueRef level);
+ LLVMValueRef level,
+ boolean lod_scalar);
#endif /* LP_BLD_SAMPLE_H */