浏览代码

Disable SSS when luxmeter is enabled

/main
Antoine Lelievre 6 年前
当前提交
ff2128f3
共有 2 个文件被更改,包括 8 次插入2 次删除
  1. 2
      com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/HDRenderPipeline.cs
  2. 8
      com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/Settings/FrameSettings.cs

2
com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/HDRenderPipeline.cs


FrameSettings currentFrameSettings = new FrameSettings();
// Get the effective frame settings for this camera taking into account the global setting and camera type
FrameSettings.InitializeFrameSettings(camera, m_Asset.GetRenderPipelineSettings(), srcFrameSettings, ref currentFrameSettings);
FrameSettings.InitializeFrameSettings(camera, m_Asset.GetRenderPipelineSettings(), m_DebugDisplaySettings, srcFrameSettings, ref currentFrameSettings);
// This is the main command buffer used for the frame.
var cmd = CommandBufferPool.Get("");

8
com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/Settings/FrameSettings.cs


// Init a FrameSettings from renderpipeline settings, frame settings and debug settings (if any)
// This will aggregate the various option
public static void InitializeFrameSettings(Camera camera, RenderPipelineSettings renderPipelineSettings, FrameSettings srcFrameSettings, ref FrameSettings aggregate)
public static void InitializeFrameSettings(Camera camera, RenderPipelineSettings renderPipelineSettings, DebugDisplaySettings debugDisplaySettings, FrameSettings srcFrameSettings, ref FrameSettings aggregate)
{
if (aggregate == null)
aggregate = new FrameSettings();

aggregate.enableDistortion = false;
aggregate.enablePostprocess = false;
aggregate.enableStereo = false;
}
// Disable SSS if luxmeter is enabled
if (debugDisplaySettings.lightingDebugSettings.debugLightingMode == DebugLightingMode.LuxMeter)
{
aggregate.enableSubsurfaceScattering = false;
}
LightLoopSettings.InitializeLightLoopSettings(camera, aggregate, renderPipelineSettings, srcFrameSettings, ref aggregate.lightLoopSettings);

正在加载...
取消
保存