mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-05 22:47:03 +00:00
rsx/vk: Rework MSAA implementation
This commit is contained in:
parent
9c5ed01130
commit
bc7ed8eaab
30 changed files with 285 additions and 123 deletions
|
|
@ -1101,9 +1101,19 @@ bool FragmentProgramDecompiler::handle_tex_srb(u32 opcode)
|
|||
|
||||
ensure(func_id <= FUNCTION::TEXTURE_SAMPLE_MAX_BASE_ENUM && func_id >= FUNCTION::TEXTURE_SAMPLE_BASE);
|
||||
|
||||
// Clamp type to 3 types (1d, 2d, cube+3d) and offset into sampling redirection table
|
||||
const auto type_offset = (std::min(static_cast<int>(type), 2) + 1) * static_cast<int>(FUNCTION::TEXTURE_SAMPLE_BASE_ENUM_COUNT);
|
||||
func_id = static_cast<FUNCTION>(static_cast<int>(func_id) + type_offset);
|
||||
if (!(m_prog.texture_state.multisampled_textures & ref_mask)) [[ likely ]]
|
||||
{
|
||||
// Clamp type to 3 types (1d, 2d, cube+3d) and offset into sampling redirection table
|
||||
const auto type_offset = (std::min(static_cast<int>(type), 2) + 1) * static_cast<int>(FUNCTION::TEXTURE_SAMPLE_BASE_ENUM_COUNT);
|
||||
func_id = static_cast<FUNCTION>(static_cast<int>(func_id) + type_offset);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Map to multisample op
|
||||
ensure(type <= rsx::texture_dimension_extended::texture_dimension_2d);
|
||||
properties.multisampled_sampler_mask |= ref_mask;
|
||||
func_id = static_cast<FUNCTION>(static_cast<int>(func_id) - static_cast<int>(FUNCTION::TEXTURE_SAMPLE_BASE) + static_cast<int>(FUNCTION::TEXTURE_SAMPLE2DMS));
|
||||
}
|
||||
|
||||
if (dst.exp_tex)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue