From f8b7f95f4e59e72796f56e3ace7a862d83779ba0 Mon Sep 17 00:00:00 2001 From: FrancescoC-Unity Date: Wed, 1 Jul 2020 18:56:48 +0200 Subject: [PATCH] Slight change of parametrization behaviour --- .../Documentation~/Override-Exposure.md | 2 +- .../Runtime/PostProcessing/Components/Exposure.cs | 4 ++-- .../Runtime/PostProcessing/PostProcessSystem.cs | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/com.unity.render-pipelines.high-definition/Documentation~/Override-Exposure.md b/com.unity.render-pipelines.high-definition/Documentation~/Override-Exposure.md index 390ca007520..21aa312913b 100644 --- a/com.unity.render-pipelines.high-definition/Documentation~/Override-Exposure.md +++ b/com.unity.render-pipelines.high-definition/Documentation~/Override-Exposure.md @@ -90,7 +90,7 @@ To configure **Automatic Mode**, select the **Metering Mode**. This tells the Ca | **Center Around Exposure target** | Whether the procedural mask will be centered around the GameObject set as Exposure Target in the [Camera](HDRP-Camera.html). | | **Center** | Sets the center of the procedural metering mask ([0,0] being bottom left of the screen and [1,1] top right of the screen). Available only when **Center Around Exposure target** is disabled. | | **Offset** | Sets an offset to where mask is centered . Available only when **Center Around Exposure target** is enabled. | - | **Radii** | Sets the radii (horizontal and vertical) of the procedural mask, in terms of fraction of the screen (i.e. 0.5 means a radius that stretches half of the screen). | + | **Radii** | Sets the radii (horizontal and vertical) of the procedural mask, in terms of fraction of half the screen (i.e. 0.5 means a mask that stretch half of the screen in both directions). | | **Softness** | Sets the softness of the mask, the higher the value the less influence is given to pixels at the edge of the mask. | | **Mask Min Intensity** | All pixels below this threshold (in EV100 units) will be assigned a weight of 0 in the metering mask. | | **Mask Max Intensity** | All pixels above this threshold (in EV100 units) will be assigned a weight of 0 in the metering mask. | diff --git a/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/Components/Exposure.cs b/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/Components/Exposure.cs index 45b560bad65..1cdd5edd4f8 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/Components/Exposure.cs +++ b/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/Components/Exposure.cs @@ -137,9 +137,9 @@ public sealed class Exposure : VolumeComponent, IPostProcessComponent /// public NoInterpVector2Parameter proceduralCenter = new NoInterpVector2Parameter(new Vector2(0.5f, 0.5f)); /// - /// Sets the radii of the procedural mask, in terms of fraction of the screen (i.e. 0.5 means a radius that stretch half of the screen). + /// Sets the radii of the procedural mask, in terms of fraction of half the screen (i.e. 0.5 means a mask that stretch half of the screen in both directions). /// - public NoInterpVector2Parameter proceduralRadii = new NoInterpVector2Parameter(new Vector2(0.15f, 0.15f)); + public NoInterpVector2Parameter proceduralRadii = new NoInterpVector2Parameter(new Vector2(0.3f, 0.3f)); /// /// All pixels below this threshold (in EV100 units) will be assigned a weight of 0 in the metering mask. /// diff --git a/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/PostProcessSystem.cs b/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/PostProcessSystem.cs index 4f5052dbf5d..ff4e475544c 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/PostProcessSystem.cs +++ b/com.unity.render-pipelines.high-definition/Runtime/PostProcessing/PostProcessSystem.cs @@ -1150,8 +1150,8 @@ internal void ComputeProceduralMeteringParams(HDCamera camera, out Vector4 proce float screenDiagonal = 0.5f * (camera.actualHeight + camera.actualWidth); proceduralParams1 = new Vector4(proceduralCenter.x, proceduralCenter.y, - m_Exposure.proceduralRadii.value.x * screenDiagonal, - m_Exposure.proceduralRadii.value.y * screenDiagonal); + m_Exposure.proceduralRadii.value.x * camera.actualWidth, + m_Exposure.proceduralRadii.value.y * camera.actualHeight); proceduralParams2 = new Vector4(1.0f / m_Exposure.proceduralSoftness.value, LightUtils.ConvertEvToLuminance(m_Exposure.maskMinIntensity.value), LightUtils.ConvertEvToLuminance(m_Exposure.maskMaxIntensity.value), 0.0f); }