Compare commits

...

4 Commits

Author SHA1 Message Date
Ty 3580ad67b6
Merge a08d8b3add into 5486eed151 2024-09-19 03:42:40 +03:00
lightningterror 5486eed151 GS/HW: Merge blend ad a mask separate conditions in to one.
Duplicate code.
2024-09-19 00:19:05 +02:00
Ty Lamontagne d1721360ff
DebugInterface: Fix formatting 2024-09-18 16:57:20 -04:00
Ty Lamontagne a08d8b3add
Debugger: Tighten valid vmstate for the cpu interface 2024-07-19 20:56:15 -04:00
2 changed files with 5 additions and 10 deletions

View File

@ -265,7 +265,8 @@ bool DebugInterface::m_pause_on_entry = false;
bool DebugInterface::isAlive() bool DebugInterface::isAlive()
{ {
return VMManager::HasValidVM() && g_FrameCount > 0; const VMState state = VMManager::GetState();
return (state == VMState::Running || state == VMState::Paused) && g_FrameCount > 0;
} }
bool DebugInterface::isCpuPaused() bool DebugInterface::isCpuPaused()
@ -829,7 +830,7 @@ bool R5900DebugInterface::isValidAddress(u32 addr)
break; break;
case 8: case 8:
case 0xA: case 0xA:
if(lopart <= 0xFFFFF) if (lopart <= 0xFFFFF)
return true; return true;
break; break;
case 9: case 9:

View File

@ -4208,14 +4208,8 @@ void GSRendererHW::EmulateBlending(int rt_alpha_min, int rt_alpha_max, const boo
const bool alpha_mask = (m_cached_ctx.FRAME.FBMSK & 0xFF000000) == 0xFF000000; const bool alpha_mask = (m_cached_ctx.FRAME.FBMSK & 0xFF000000) == 0xFF000000;
bool blend_ad_alpha_masked = blend_ad && alpha_mask; bool blend_ad_alpha_masked = blend_ad && alpha_mask;
const bool is_basic_blend = GSConfig.AccurateBlendingUnit >= AccBlendLevel::Basic; const bool is_basic_blend = GSConfig.AccurateBlendingUnit >= AccBlendLevel::Basic;
if ((is_basic_blend || (COLCLAMP.CLAMP == 0)) && features.texture_barrier && blend_ad_alpha_masked) if (blend_ad_alpha_masked && (((is_basic_blend || (COLCLAMP.CLAMP == 0)) && features.texture_barrier)
{ || ((GSConfig.AccurateBlendingUnit >= AccBlendLevel::Medium) || m_conf.require_one_barrier)))
// Swap Ad with As for hw blend.
m_conf.ps.a_masked = 1;
m_conf.ps.blend_c = 0;
m_conf.require_one_barrier |= true;
}
else if (((GSConfig.AccurateBlendingUnit >= AccBlendLevel::Medium) || m_conf.require_one_barrier) && blend_ad_alpha_masked)
{ {
// Swap Ad with As for hw blend. // Swap Ad with As for hw blend.
m_conf.ps.a_masked = 1; m_conf.ps.a_masked = 1;