docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method DefragAtlas

    DefragAtlas(HDLightType)

    If a light is added after a scene is loaded, its placement in the atlas might be not optimal and the suboptimal placement might prevent a light to find a place in the atlas. This function will force a defragmentation of the atlas containing lights of type lightType and redistributes the shadows inside so that the placement is optimal. Note however that this will also mark the shadow maps as dirty and they will be re-rendered as soon the light will come into view for the first time after this function call.

    Declaration
    public void DefragAtlas(HDLightType lightType)
    Parameters
    Type Name Description
    HDLightType lightType

    The type of the light contained in the atlas that need defragmentation.

    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)