浏览代码

HDRenderPipeline: Fix issue with debug menu and graphic test

/main
sebastienlagarde 7 年前
当前提交
1b720002
共有 1 个文件被更改,包括 10 次插入4 次删除
  1. 14
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Debug/LightingDebugPanel.cs

14
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Debug/LightingDebugPanel.cs


public override void ValidateValues(Func<object> getter, Action<object> setter)
{
HDRenderPipeline hdPipeline = RenderPipelineManager.currentPipeline as HDRenderPipeline;
m_Max = (uint)hdPipeline.GetShadowAtlasCount() - 1;
setter(Math.Min(m_Max, Math.Max(m_Min, (uint)getter())));
if (hdPipeline != null)
{
m_Max = (uint)hdPipeline.GetShadowAtlasCount() - 1;
setter(Math.Min(m_Max, Math.Max(m_Min, (uint)getter())));
}
}
}

public override void ValidateValues(Func<object> getter, Action<object> setter)
{
HDRenderPipeline hdPipeline = RenderPipelineManager.currentPipeline as HDRenderPipeline;
m_Max = (uint)hdPipeline.GetCurrentShadowCount() - 1;
setter(Math.Min(m_Max, Math.Max(m_Min, (uint)getter())));
if (hdPipeline != null)
{
m_Max = (uint)hdPipeline.GetCurrentShadowCount() - 1;
setter(Math.Min(m_Max, Math.Max(m_Min, (uint)getter())));
}
}
}

正在加载...
取消
保存