rsx/vk: Rework MSAA implementation

This commit is contained in:
kd-11 2022-03-13 11:32:04 +03:00 committed by kd-11
parent 9c5ed01130
commit bc7ed8eaab
30 changed files with 285 additions and 123 deletions

View file

@ -1738,6 +1738,12 @@ namespace rsx
{
current_vp_texture_state.clear(i);
current_vp_texture_state.set_dimension(sampler_descriptors[i]->image_type, i);
if (backend_config.supports_hw_msaa &&
sampler_descriptors[i]->samples > 1)
{
current_vp_texture_state.multisampled_textures |= (1 << i);
}
}
}
@ -1978,6 +1984,15 @@ namespace rsx
}
}
if (backend_config.supports_hw_msaa &&
sampler_descriptors[i]->samples > 1)
{
current_fp_texture_state.multisampled_textures |= (1 << i);
texture_control |= (static_cast<u32>(tex.zfunc()) << texture_control_bits::DEPTH_COMPARE_OP);
texture_control |= (static_cast<u32>(tex.mag_filter() != rsx::texture_magnify_filter::nearest) << texture_control_bits::FILTERED);
texture_control |= (((tex.format() & CELL_GCM_TEXTURE_UN) >> 6) << texture_control_bits::UNNORMALIZED_COORDS);
}
if (sampler_descriptors[i]->format_class != RSX_FORMAT_CLASS_COLOR)
{
switch (sampler_descriptors[i]->format_class)