docs.unity.cn
Search Results for

    Show / Hide Table of Contents

    Method ConstrainYaw

    ConstrainYaw(Quaternion)

    Returns a rotation that only contains the yaw component of the specified rotation. The resulting rotation is not normalized.

    Declaration
    public static Quaternion ConstrainYaw(this Quaternion rotation)
    Parameters
    Type Name Description
    Quaternion rotation

    The source rotation.

    Returns
    Type Description
    Quaternion

    A yaw-only rotation that matches the input rotation's yaw.

    In This Article
    Back to top
    Copyright © 2024 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)