Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,20 @@ The **Fog** override of the active Volume controls the appearance of the global
| **- Mip Fog Far** | The distance (in meters) from the Camera that HDRP starts sampling the highest resolution mipmap for the fog color.<br />This property only appears when you select **Sky Color** from the **Color Mode** drop-down. |
| **- Mip Fog Max Mip** | Use the slider to set the maximum mipmap that HDRP uses for the mip fog. This defines the mipmap that HDRP samples for distances greater than **Mip Fog Far**.<br />This property only appears when you select **Sky Color** from the **Color Mode** drop-down. |
| **- Constant Color** | Use the color picker to select the color of the fog.<br />This property only appears when you select **Constant Color** from the **Color Mode** drop-down. |
| **Volumetric Fog** | Enables Volumetric Fog. |
| **Albedo** | Sets the fog color. Volumetric Fog tints lighting, so the fog scatters light to this color. It only tints lighting emitted by Lights behind or within the fog. This means that it does not tint lighting that reflects off GameObjects behind or within the fog - reflected lighting only gets dimmer (fades to black) as fog density increases. For example, if you shine a Light at a white wall behind fog with red Single Scattering Albedo, the fog looks red. If you shine a Light at a white wall and view it from the other side of the fog, the fog darkens the light but doesn’t tint it red. |
| **Anisotropy** | Controls the angular distribution of scattered light. 0 is isotropic, 1 is forward scattering, and -1 is backward scattering. Note that non-zero values have a moderate performance impact. High values may have compatibility issues with the Enable Reprojection for Volumetrics Frame Setting. This is an experimental property that HDRP applies to both global and local fog. |
| **Ambient Light Probe Dimmer** | Reduces the intensity of the global Ambient Light Probe that the sky generates. |
| **Depth Extent** | Determines the distance (in meters) from the Camera at which the volumetric fog section of the frustum ends. |
| **Slice Distribution Uniformity** | Controls the uniformity of the distribution of slices along the Camera's focal axis. HDRP samples volumetric fog at multiple distances from the Camera. Each of these sample areas is called a slice. A value of 0 makes the distribution of slices exponential (the spacing between the slices increases with the distance from the Camera) which gives greater precision near to the Camera, and lower precision further away. A value of 1 results in a uniform distribution which gives the same level of precision regardless of the distance to the Camera. |
| **Filter** | Applies a blur to smoothen the volumetric lighting output. |
| **Volumetric Fog** | Indicates whether HDRP should calculate volumetric fog or not. |
| - **Albedo** | The color of the volumetric fog to. Volumetric fog tints lighting, so the fog scatters light to this color. It only tints lighting emitted by Lights behind or within the fog. This means that it does not tint lighting that reflects off GameObjects behind or within the fog - reflected lighting only gets dimmer (fades to black) as fog density increases. For example, if you shine a Light at a white wall through fog with a red **Albedo**, the fog looks red. If you shine a Light at a white wall and view it from the other side of the fog, the fog darkens the light but doesn’t tint it red. |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo

| - **Ambient Light Probe Dimmer** | The amount to dim the intensity of the global ambient light probe that the sky generates. A value of 0 does not dim the light probe and a value of 1 fully dims the light probe. |
| - **Volumetric Fog Distance** | The distance (in meters) from the Camera at which the volumetric fog section of the frustum ends. |
| - **Denoising Mode** | The denoising technique to use for the volumetric fog. The options are:<br/>&#8226; **None**: Applies no denoising.<br/>&#8226; **Reprojection**: A denoising technique that is very effective for static lighting, but can lead to severe ghosting for highly dynamic lighting.<br/>&#8226; **Gaussian**: A denoising technique that is better than **Reprojection** for dynamic lighting.<br/>&#8226; **Both**: Applies both **Reprojection** and **Gaussian** techniques. Using both techniques can produce high quality results but significantly increases the resource intensity of the effect. |
| - **Slice Distribution Uniformity** | The uniformity of the distribution of slices along the Camera's forward axis. HDRP samples volumetric fog at multiple distances from the Camera. Each of these sample areas is called a slice. A value of 0 makes the distribution of slices exponential (the spacing between the slices increases with the distance from the Camera) which gives greater precision near to the Camera, and lower precision further away. A value of 1 results in a uniform distribution which gives the same level of precision regardless of the distance to the Camera. |
| - **Quality** | Specifies the preset HDRP uses to populate the values of the following nested properties. The options are:<br/>&#8226; **Low**: A preset that emphasizes performance over quality.<br/>&#8226; **Medium**: A preset that balances performance and quality.<br/>&#8226; **High**: A preset that emphasizes quality over performance.<br/>&#8226; **Custom**: Allows you to override each property individually.<br/>If you select any value other than **Custom**, **Fog Control Mode** switches to **Balance**. |
| - - **Fog Control Mode** | Specifies the method to use to control the performance and quality of the volumetric fog. The options are:<br/>&#8226; **Balance**: Uses a performance-oriented approach to define the quality of the volumetric fog.<br/>&#8226; **Manual**: Gives you access to the internal set of properties which directly control the effect. |
| - - - **Volumetric Fog Budget** | The performance to quality ratio of the volumetric fog. A value of 0 being the least resource-intensive and a value of 1 being the highest quality.<br/>This property only appears if you set **Fog Control Mode** to **Balance**. |
| - - - **Resolution Depth Ratio** | The ratio HDRP uses to share resources between the screen (x-axis and y-axis) and the depth (z-axis) resolutions.<br/>This property only appears if you set **Fog Control Mode** to **Balance**. |
| - - - **Screen Resolution Percentage** | The resolution of the volumetric buffer (3D texture) along the x-axis and y-axis relative to the resolution of the screen.<br/>This property only appears if you set **Fog Control Mode** to **Manual**. |
| - - - **Volume Slice Count** | The number of slices to use for the volumetric buffer (3D texture) along the camera's focal axis.<br/>This property only appears if you set **Fog Control Mode** to **Manual**. |
| - **Directional Lights Only** | Indicates whether HDRP only process volumetric fog for directional [Lights](Light-Component.md) or for all Lights. Including non-directional Lights increases the resource intensity of the effect. |
| - **Anisotropy** | Controls the angular distribution of scattered light. 0 is isotropic, 1 is forward scattering, and -1 is backward scattering. Note that non-zero values have a moderate performance impact. High values may have compatibility issues with the **Enable Reprojection for Volumetrics** Frame Setting. This is an experimental property that HDRP applies to both global and local fog. |


## Light-specific Properties
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public class Fog : VolumeComponentWithQuality
public MinFloatParameter depthExtent = new MinFloatParameter(64.0f, 0.1f);
/// <summary>Controls which denoising technique to use for the volumetric effect.</summary>
/// <remarks>Reprojection mode is effective for static lighting but can lead to severe ghosting artifacts with highly dynamic lighting. Gaussian mode is effective with dynamic lighting. You can also use both modes together which produces high-quality results, but increases the resource intensity of processing the effect.</remarks>
[Tooltip("Controls which denoising technique to use for the volumetric effect. Reprojection is very effective for static lighting, but can lead to severe ghosting for highly dynamic lighting. Gaussian is a good alternative for dynamic lighting. Using both techniques can give high quality results but significantly increases the resource intensity of the effect.")]
[Tooltip("Specifies the denoising technique to use for the volumetric effect.")]
public FogDenoisingModeParameter denoisingMode = new FogDenoisingModeParameter(FogDenoisingMode.Gaussian);

// Advanced parameters
Expand Down Expand Up @@ -89,14 +89,14 @@ public FogControl fogControlMode
set { m_FogControlMode.value = value; }
}
[SerializeField, FormerlySerializedAs("fogControlMode")]
[Tooltip("Controls which method to use to control the performance and quality of the volumetric fog. Balance mode allows you to use a performance-oriented approach to define the quality of the volumetric fog. Manual mode gives you access to the internal set of properties which directly control the effect.")]
[Tooltip("Specifies which method to use to control the performance and quality of the volumetric fog.")]
private FogControlParameter m_FogControlMode = new FogControlParameter(FogControl.Balance);

/// <summary>Stores the resolution of the volumetric buffer (3D texture) along the x-axis and y-axis relative to the resolution of the frame buffer.</summary>
[Tooltip("Stores the resolution of the volumetric buffer (3D texture) along the x-axis and y-axis relative to the resolution of the frame buffer.")]
/// <summary>Stores the resolution of the volumetric buffer (3D texture) along the x-axis and y-axis relative to the resolution of the screen.</summary>
[Tooltip("Controls the resolution of the volumetric buffer (3D texture) along the x-axis and y-axis relative to the resolution of the screen.")]
public ClampedFloatParameter screenResolutionPercentage = new ClampedFloatParameter(optimalFogScreenResolutionPercentage, minFogScreenResolutionPercentage, maxFogScreenResolutionPercentage);
/// <summary>Number of slices of the volumetric buffer (3D texture) along the camera's focal axis.</summary>
[Tooltip("Number of slices of the volumetric buffer (3D texture) along the camera's focal axis.")]
[Tooltip("Controls the number of slices to use the volumetric buffer (3D texture) along the camera's focal axis.")]
public ClampedIntParameter volumeSliceCount = new ClampedIntParameter(64, 1, maxFogSliceCount);

/// <summary>Defines the performance to quality ratio of the volumetric fog. A value of 0 being the least resource-intensive and a value of 1 being the highest quality.</summary>
Expand All @@ -113,7 +113,7 @@ public float volumetricFogBudget
set { m_VolumetricFogBudget.value = value; }
}
[SerializeField, FormerlySerializedAs("volumetricFogBudget")]
[Tooltip("Defines the performance to quality ratio of the volumetric fog. A value of 0 being the least resource-intensive and a value of 1 being the highest quality.")]
[Tooltip("Controls the performance to quality ratio of the volumetric fog. A value of 0 being the least resource-intensive and a value of 1 being the highest quality.")]
private ClampedFloatParameter m_VolumetricFogBudget = new ClampedFloatParameter(0.25f, 0.0f, 1.0f);

/// <summary>Controls how Unity shares resources between Screen (XY) and Depth (Z) resolutions.</summary>
Expand All @@ -130,11 +130,11 @@ public float resolutionDepthRatio
set { m_ResolutionDepthRatio.value = value; }
}
[SerializeField, FormerlySerializedAs("resolutionDepthRatio")]
[Tooltip("Controls how Unity shares resources between Screen (XY) and Depth (Z) resolutions.")]
[Tooltip("Controls how Unity shares resources between Screen (x-axis and y-axis) and Depth (z-axis) resolutions.")]
public ClampedFloatParameter m_ResolutionDepthRatio = new ClampedFloatParameter(0.5f, 0.0f, 1.0f);

/// <summary>Indicates whether Unity includes or excludes non-directional light types when it evaluates the volumetric fog. Including non-directional lights increases the resource intensity of the effect.</summary>
[Tooltip("Indicates whether Unity includes or excludes non-directional light types when it evaluates the volumetric fog. Including non-directional lights increases the resource intensity of the effect.")]
[Tooltip("When enabled, HDRP only includes directional Lights when it evaluates volumetric fog.")]
public BoolParameter directionalLightsOnly = new BoolParameter(false);

internal static bool IsFogEnabled(HDCamera hdCamera)
Expand Down