mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 21:30:19 -06:00
First Stage:
Fix depth related errors in dstalpha pass. best place to test: water splash effect in super mario galaxy
This commit is contained in:
@ -1211,11 +1211,11 @@ void Renderer::RestoreAPIState()
|
||||
BPFunctions::SetScissor();
|
||||
}
|
||||
|
||||
void Renderer::ApplyState(bool bUseDstAlpha)
|
||||
void Renderer::ApplyState(u32 mode)
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
if (bUseDstAlpha)
|
||||
if (mode & RSM_UseDstAlpha)
|
||||
{
|
||||
// Colors should blend against SRC1_ALPHA
|
||||
if (gx_state.blenddc.RenderTarget[0].SrcBlend == D3D11_BLEND_SRC_ALPHA)
|
||||
@ -1275,7 +1275,7 @@ void Renderer::ApplyState(bool bUseDstAlpha)
|
||||
|
||||
D3D::stateman->Apply();
|
||||
|
||||
if (bUseDstAlpha)
|
||||
if (mode & RSM_UseDstAlpha)
|
||||
{
|
||||
// restore actual state
|
||||
SetBlendMode(false);
|
||||
|
@ -25,7 +25,7 @@ public:
|
||||
void SetInterlacingMode();
|
||||
|
||||
// TODO: Fix confusing names (see ResetAPIState and RestoreAPIState)
|
||||
void ApplyState(bool bUseDstAlpha);
|
||||
void ApplyState(u32 mode);
|
||||
void RestoreState();
|
||||
|
||||
void ApplyCullDisable();
|
||||
|
@ -264,7 +264,7 @@ void VertexManager::vFlush()
|
||||
unsigned int stride = g_nativeVertexFmt->GetVertexStride();
|
||||
g_nativeVertexFmt->SetupVertexPointers();
|
||||
|
||||
g_renderer->ApplyState(useDstAlpha);
|
||||
g_renderer->ApplyState(useDstAlpha ? RSM_UseDstAlpha : RSM_None);
|
||||
LoadBuffers();
|
||||
Draw(stride);
|
||||
|
||||
|
Reference in New Issue
Block a user