compressed_colortex_counter = p_atomic_read(&sctx->screen->b.compressed_colortex_counter);
if (compressed_colortex_counter != sctx->b.last_compressed_colortex_counter) {
sctx->b.last_compressed_colortex_counter = compressed_colortex_counter;
- si_update_compressed_colortex_masks(sctx);
+ si_update_needs_color_decompress_masks(sctx);
}
/* Decompress color & depth textures if needed. */
- mask = sctx->compressed_tex_shader_mask & shader_mask;
+ mask = sctx->shader_needs_decompress_mask & shader_mask;
while (mask) {
unsigned i = u_bit_scan(&mask);
!r600_can_sample_zs(rtex, sview->is_stencil_sampler));
}
-static void si_update_compressed_tex_shader_mask(struct si_context *sctx,
- unsigned shader)
+static void si_update_shader_needs_decompress_mask(struct si_context *sctx,
+ unsigned shader)
{
struct si_textures_info *samplers = &sctx->samplers[shader];
unsigned shader_bit = 1 << shader;
if (samplers->needs_depth_decompress_mask ||
samplers->needs_color_decompress_mask ||
sctx->images[shader].needs_color_decompress_mask)
- sctx->compressed_tex_shader_mask |= shader_bit;
+ sctx->shader_needs_decompress_mask |= shader_bit;
else
- sctx->compressed_tex_shader_mask &= ~shader_bit;
+ sctx->shader_needs_decompress_mask &= ~shader_bit;
}
static void si_set_sampler_views(struct pipe_context *ctx,
}
}
- si_update_compressed_tex_shader_mask(sctx, shader);
+ si_update_shader_needs_decompress_mask(sctx, shader);
}
static void
-si_samplers_update_compressed_colortex_mask(struct si_textures_info *samplers)
+si_samplers_update_needs_color_decompress_mask(struct si_textures_info *samplers)
{
unsigned mask = samplers->views.enabled_mask;
si_set_shader_image(ctx, shader, slot, NULL, false);
}
- si_update_compressed_tex_shader_mask(ctx, shader);
+ si_update_shader_needs_decompress_mask(ctx, shader);
}
static void
-si_images_update_compressed_colortex_mask(struct si_images_info *images)
+si_images_update_needs_color_decompress_mask(struct si_images_info *images)
{
unsigned mask = images->enabled_mask;
/* CMASK can be enabled (for fast clear) and disabled (for texture export)
* while the texture is bound, possibly by a different context. In that case,
- * call this function to update compressed_colortex_masks.
+ * call this function to update needs_*_decompress_masks.
*/
-void si_update_compressed_colortex_masks(struct si_context *sctx)
+void si_update_needs_color_decompress_masks(struct si_context *sctx)
{
for (int i = 0; i < SI_NUM_SHADERS; ++i) {
- si_samplers_update_compressed_colortex_mask(&sctx->samplers[i]);
- si_images_update_compressed_colortex_mask(&sctx->images[i]);
- si_update_compressed_tex_shader_mask(sctx, i);
+ si_samplers_update_needs_color_decompress_mask(&sctx->samplers[i]);
+ si_images_update_needs_color_decompress_mask(&sctx->images[i]);
+ si_update_shader_needs_decompress_mask(sctx, i);
}
}
samplers->views[i], true);
}
- si_update_compressed_tex_shader_mask(sctx, shader);
+ si_update_shader_needs_decompress_mask(sctx, shader);
}
}