docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class ShadowUtils

    Various utility functions used for shadows.

    Inheritance
    object
    ShadowUtils
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.Rendering.Universal
    Assembly: Unity.RenderPipelines.Universal.Runtime.dll
    Syntax
    public static class ShadowUtils

    Methods

    Name Description
    AllocShadowRT(int, int, int, int, float, string)

    Allocate a Shadow Map

    ApplySliceTransform(ref ShadowSliceData, int, int)

    Used for baking bake cascade transforms in each shadow matrix.

    ExtractDirectionalLightMatrix(ref CullingResults, ref ShadowData, int, int, int, int, int, float, out Vector4, out ShadowSliceData)

    Extracts the directional light matrix.

    ExtractDirectionalLightMatrix(ref CullingResults, ref ShadowData, int, int, int, int, int, float, out Vector4, out ShadowSliceData, out Matrix4x4, out Matrix4x4)

    Extracts the directional light matrix.

    ExtractPointLightMatrix(ref CullingResults, ref ShadowData, int, CubemapFace, float, out Matrix4x4, out Matrix4x4, out Matrix4x4, out ShadowSplitData)

    Extracts the spot light matrix.

    ExtractSpotLightMatrix(ref CullingResults, ref ShadowData, int, out Matrix4x4, out Matrix4x4, out Matrix4x4, out ShadowSplitData)

    Extracts the spot light matrix.

    GetMaxTileResolutionInAtlas(int, int, int)

    Calculates the maximum tile resolution in an Atlas.

    GetShadowBias(ref VisibleLight, int, ref ShadowData, Matrix4x4, float)

    Calculates the depth and normal bias from a light.

    RenderShadowSlice(CommandBuffer, ref ScriptableRenderContext, ref ShadowSliceData, ref ShadowDrawingSettings)

    Renders shadows to a shadow slice.

    RenderShadowSlice(CommandBuffer, ref ScriptableRenderContext, ref ShadowSliceData, ref ShadowDrawingSettings, Matrix4x4, Matrix4x4)

    Renders shadows to a shadow slice.

    SetupShadowCasterConstantBuffer(CommandBuffer, ref VisibleLight, Vector4)

    Sets up the shadow bias, light direction and position for rendering.

    ShadowRTNeedsReAlloc(RTHandle, int, int, int, int, float, string)

    Return true if handle does not match the requirements

    ShadowRTReAllocateIfNeeded(ref RTHandle, int, int, int, int, float, string)

    Allocate a Shadow Map or re-allocate if it doesn't match requirements. For use only if the map requirements changes at runtime.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)