docs.unity3d.com
    Show / Hide Table of Contents

    Class AmbientOcclusion

    This class holds settings for the Ambient Occlusion effect.

    Inheritance
    Object
    Object
    ScriptableObject
    PostProcessEffectSettings
    AmbientOcclusion
    Inherited Members
    PostProcessEffectSettings.active
    PostProcessEffectSettings.enabled
    PostProcessEffectSettings.SetAllOverridesTo(Boolean, Boolean)
    PostProcessEffectSettings.GetHash()
    ScriptableObject.SetDirty()
    ScriptableObject.CreateInstance(String)
    ScriptableObject.CreateInstance(Type)
    ScriptableObject.CreateInstance<T>()
    Object.GetInstanceID()
    Object.GetHashCode()
    Object.Equals(Object)
    Object.Instantiate(Object, Vector3, Quaternion)
    Object.Instantiate(Object, Vector3, Quaternion, Transform)
    Object.Instantiate(Object)
    Object.Instantiate(Object, Transform)
    Object.Instantiate(Object, Transform, Boolean)
    Object.Instantiate<T>(T)
    Object.Instantiate<T>(T, Vector3, Quaternion)
    Object.Instantiate<T>(T, Vector3, Quaternion, Transform)
    Object.Instantiate<T>(T, Transform)
    Object.Instantiate<T>(T, Transform, Boolean)
    Object.Destroy(Object, Single)
    Object.Destroy(Object)
    Object.DestroyImmediate(Object, Boolean)
    Object.DestroyImmediate(Object)
    Object.FindObjectsOfType(Type)
    Object.DontDestroyOnLoad(Object)
    Object.DestroyObject(Object, Single)
    Object.DestroyObject(Object)
    Object.FindSceneObjectsOfType(Type)
    Object.FindObjectsOfTypeIncludingAssets(Type)
    Object.FindObjectsOfType<T>()
    Object.FindObjectOfType<T>()
    Object.FindObjectsOfTypeAll(Type)
    Object.FindObjectOfType(Type)
    Object.ToString()
    Object.name
    Object.hideFlags
    Namespace: UnityEngine.Rendering.PostProcessing
    Syntax
    [Serializable]
    public sealed class AmbientOcclusion : PostProcessEffectSettings

    Fields

    ambientOnly

    Only affects ambient lighting. This mode is only available with the Deferred rendering path and HDR rendering. Objects rendered with the Forward rendering path won't get any ambient occlusion.

    Declaration
    [Tooltip("Check this box to mark this Volume as to only affect ambient lighting. This mode is only available with the Deferred rendering path and HDR rendering. Objects rendered with the Forward rendering path won't get any ambient occlusion.")]
    public BoolParameter ambientOnly
    Field Value
    Type Description
    BoolParameter

    blurTolerance

    The tolerance of the bilateral blur filter to depth changes.

    Declaration
    [Range(-8F, -1F)]
    public FloatParameter blurTolerance
    Field Value
    Type Description
    FloatParameter

    color

    A custom color to use for the ambient occlusion.

    Declaration
    [ColorUsage(false)]
    [Tooltip("The custom color to use for the ambient occlusion. The default is black.")]
    public ColorParameter color
    Field Value
    Type Description
    ColorParameter

    directLightingStrength

    Modifies he influence of direct lighting on ambient occlusion. This is only used in the HD Render Pipeline currently.

    Declaration
    [Range(0F, 1F)]
    [Tooltip("Modifies the influence of direct lighting on ambient occlusion.")]
    public FloatParameter directLightingStrength
    Field Value
    Type Description
    FloatParameter

    intensity

    The degree of darkness added by ambient occlusion.

    Declaration
    [Range(0F, 4F)]
    [Tooltip("The degree of darkness added by ambient occlusion. Higher values produce darker areas.")]
    public FloatParameter intensity
    Field Value
    Type Description
    FloatParameter

    mode

    The ambient occlusion method to use.

    Declaration
    [Tooltip("The ambient occlusion method to use. \"Multi Scale Volumetric Obscurance\" is higher quality and faster on desktop & console platforms but requires compute shader support.")]
    public AmbientOcclusionModeParameter mode
    Field Value
    Type Description
    AmbientOcclusionModeParameter

    noiseFilterTolerance

    The tolerance of the noise filter to changes in the depth pyramid.

    Declaration
    [Range(-8F, 0F)]
    public FloatParameter noiseFilterTolerance
    Field Value
    Type Description
    FloatParameter

    quality

    The number of sample points, which affects quality and performance. Lowest, Low and Medium passes are downsampled. High and Ultra are not and should only be used on high-end hardware.

    Declaration
    [Tooltip("The number of sample points. This affects both quality and performance. For \"Lowest\", \"Low\", and \"Medium\", passes are downsampled. For \"High\" and \"Ultra\", they are not and therefore you should only \"High\" and \"Ultra\" on high-end hardware.")]
    public AmbientOcclusionQualityParameter quality
    Field Value
    Type Description
    AmbientOcclusionQualityParameter

    radius

    Radius of sample points, which affects extent of darkened areas.

    Declaration
    [Tooltip("The radius of sample points. This affects the size of darkened areas.")]
    public FloatParameter radius
    Field Value
    Type Description
    FloatParameter

    thicknessModifier

    Modifies the thickness of occluders. This increases dark areas but also introduces dark halo around objects.

    Declaration
    [Range(1F, 10F)]
    [Tooltip("This modifies the thickness of occluders. It increases the size of dark areas and also introduces a dark halo around objects.")]
    public FloatParameter thicknessModifier
    Field Value
    Type Description
    FloatParameter

    upsampleTolerance

    The tolerance of the upsampling pass to depth changes.

    Declaration
    [Range(-12F, -1F)]
    public FloatParameter upsampleTolerance
    Field Value
    Type Description
    FloatParameter

    Methods

    IsEnabledAndSupported(PostProcessRenderContext)

    Returns true if the effect is currently enabled and supported.

    Declaration
    public override bool IsEnabledAndSupported(PostProcessRenderContext context)
    Parameters
    Type Name Description
    PostProcessRenderContext context

    The current post-processing render context

    Returns
    Type Description
    Boolean

    true if the effect is currently enabled and supported

    Overrides
    PostProcessEffectSettings.IsEnabledAndSupported(PostProcessRenderContext)
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023