mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Merge pull request #9591 from blaahaj/sonic-epsilon
VertexShaderGen: Sonic epsilon hack for OpenGL ES
This commit is contained in:
@ -498,6 +498,12 @@ ShaderCode GenerateVertexShaderCode(APIType api_type, const ShaderHostConfig& ho
|
|||||||
"o.clipDist1 = clipDist1;\n");
|
"o.clipDist1 = clipDist1;\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Same depth adjustment for Sonic. Without depth clamping, it unfortunately
|
||||||
|
// affects non-clipping uses of depth too.
|
||||||
|
out.Write("o.pos.z = o.pos.z * (1.0 - 1e-7);\n");
|
||||||
|
}
|
||||||
|
|
||||||
// Write the true depth value. If the game uses depth textures, then the pixel shader will
|
// Write the true depth value. If the game uses depth textures, then the pixel shader will
|
||||||
// override it with the correct values if not then early z culling will improve speed.
|
// override it with the correct values if not then early z culling will improve speed.
|
||||||
|
Reference in New Issue
Block a user