diff --git a/GPU/Common/Draw2D.cpp b/GPU/Common/Draw2D.cpp index f40d746659..cd54704e9a 100644 --- a/GPU/Common/Draw2D.cpp +++ b/GPU/Common/Draw2D.cpp @@ -53,7 +53,7 @@ struct Draw2DUB { const UniformBufferDesc draw2DUBDesc{ sizeof(Draw2DUB), { { "texSize", -1, 0, UniformType::FLOAT2, 0 }, - { "scaleFactor", -1, 1, UniformType::FLOAT1, 0 }, + { "scaleFactor", -1, 1, UniformType::FLOAT1, 8 }, } }; diff --git a/GPU/GLES/StateMappingGLES.cpp b/GPU/GLES/StateMappingGLES.cpp index 25015802e6..a5dc125f5a 100644 --- a/GPU/GLES/StateMappingGLES.cpp +++ b/GPU/GLES/StateMappingGLES.cpp @@ -259,7 +259,7 @@ void DrawEngineGLES::ApplyDrawState(int prim) { if (stencilState.enabled) { renderManager->SetStencilFunc(stencilState.enabled, compareOps[stencilState.testFunc], stencilState.testRef, stencilState.testMask); renderManager->SetStencilOp(stencilState.writeMask, stencilOps[stencilState.sFail], stencilOps[stencilState.zFail], stencilOps[stencilState.zPass]); - } else { + // Nasty special case for Spongebob and similar where it tries to write zeros to alpha/stencil during // depth-fail. We can't write to alpha then because the pixel is killed. However, we can invert the depth // test and modify the alpha function... @@ -276,7 +276,7 @@ void DrawEngineGLES::ApplyDrawState(int prim) { // TODO: Need to set in a way that carries over to the next draw.. gstate_c.Dirty(DIRTY_BLEND_STATE); } - + } else { renderManager->SetStencilDisabled(); } }