v2: Bump the number of supported image uniforms to 32 (Ken).
Reviewed-by: Paul Berry <stereotype441@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
uint32_t gather_texture_start;
uint32_t ubo_start;
uint32_t abo_start;
+ uint32_t image_start;
uint32_t shader_time_start;
/** @} */
} binding_table;
/** Max number of atomic counter buffer objects in a shader */
#define BRW_MAX_ABO 16
+/** Max number of image uniforms in a shader */
+#define BRW_MAX_IMAGES 32
+
/**
* Max number of binding table entries used for stream output.
*
BRW_MAX_TEX_UNIT * 2 + /* normal, gather */ \
12 + /* ubo */ \
BRW_MAX_ABO + \
+ BRW_MAX_IMAGES + \
2 /* shader time, pull constants */)
#define SURF_INDEX_GEN6_SOL_BINDING(t) (t)
stage_prog_data->binding_table.abo_start = 0xd0d0d0d0;
}
+ if (shader && shader->base.NumImages) {
+ stage_prog_data->binding_table.image_start = next_binding_table_offset;
+ next_binding_table_offset += shader->base.NumImages;
+ } else {
+ stage_prog_data->binding_table.image_start = 0xd0d0d0d0;
+ }
+
/* This may or may not be used depending on how the compile goes. */
stage_prog_data->binding_table.pull_constants_start = next_binding_table_offset;
next_binding_table_offset++;