/* Whether or not this shader ever uses textureGather() */
bool uses_texture_gather;
+ /** Bitfield of which textures are used by texelFetch() */
+ uint32_t textures_used_by_txf;
+
/* The size of the gl_ClipDistance[] array, if declared. */
unsigned clip_distance_array_size;
GLbitfield TexturesUsed[MAX_COMBINED_TEXTURE_IMAGE_UNITS]; /**< TEXTURE_x_BIT bitmask */
GLbitfield SamplersUsed; /**< Bitfield of which samplers are used */
GLbitfield ShadowSamplers; /**< Texture units used for shadow sampling. */
- GLbitfield TexelFetchSamplers; /**< Texture units used for texelFetch*(). */
GLbitfield ExternalSamplersUsed; /**< Texture units used for samplerExternalOES */
/* Fragement shader only fields */
{
const GLuint old_max = *out_num_textures;
GLbitfield samplers_used = prog->SamplersUsed;
- GLbitfield texel_fetch_samplers = prog->TexelFetchSamplers;
+ GLbitfield texel_fetch_samplers = prog->info.textures_used_by_txf;
GLbitfield free_slots = ~prog->SamplersUsed;
GLbitfield external_samplers_used = prog->ExternalSamplersUsed;
GLuint unit;
{
v->samplers_used = 0;
v->images_used = 0;
+ prog->info.textures_used_by_txf = 0;
foreach_in_list(glsl_to_tgsi_instruction, inst, &v->instructions) {
if (inst->info->is_tex) {
st_translate_texture_target(inst->tex_target, inst->tex_shadow);
if (inst->op == TGSI_OPCODE_TXF || inst->op == TGSI_OPCODE_TXF_LZ) {
- prog->TexelFetchSamplers |= 1u << idx;
+ prog->info.textures_used_by_txf |= 1u << idx;
}
}
}