docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method SetWeight

    SetWeight(int, float)

    Set the weight of the child at an index.

    Declaration
    public void SetWeight(int index, float w)
    Parameters
    Type Name Description
    int index

    The child index. Only immediate CinemachineVirtualCameraBase children are counted.

    float w

    The weight to set. Can be any non-negative number.

    SetWeight(CinemachineVirtualCameraBase, float)

    Set the weight of the child CinemachineVirtualCameraBase.

    Declaration
    public void SetWeight(CinemachineVirtualCameraBase vcam, float w)
    Parameters
    Type Name Description
    CinemachineVirtualCameraBase vcam

    The child camera.

    float w

    The weight to set. Can be any non-negative number.

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