Support depth clip mode and disable shader fast math optimization on NVIDIA as a workaround for compiler bugs (?)

This commit is contained in:
gdkchan 2019-12-07 01:54:28 -03:00 committed by Thog
parent 17fb11ddb9
commit 7ce5584f9e
7 changed files with 55 additions and 4 deletions

View file

@ -102,7 +102,7 @@ namespace Ryujinx.Graphics.Gpu.Engine
UpdateDepthTestState(state);
}
if (state.QueryModified(MethodOffset.ViewportTransform, MethodOffset.ViewportExtents))
if (state.QueryModified(MethodOffset.DepthMode, MethodOffset.ViewportTransform, MethodOffset.ViewportExtents))
{
UpdateViewportTransform(state);
}
@ -294,6 +294,10 @@ namespace Ryujinx.Graphics.Gpu.Engine
private void UpdateViewportTransform(GpuState state)
{
DepthMode depthMode = state.Get<DepthMode>(MethodOffset.DepthMode);
_context.Renderer.Pipeline.SetDepthMode(depthMode);
bool transformEnable = GetViewportTransformEnable(state);
bool flipY = (state.Get<int>(MethodOffset.YControl) & 1) != 0;