Class QuaternionExtensions | Unity Reflect | 1.1.0-preview.6
docs.unity.cn
    Show / Hide Table of Contents

    Class QuaternionExtensions

    Inheritance
    Object
    QuaternionExtensions
    Namespace: Unity.Labs.Utils
    Syntax
    public static class QuaternionExtensions

    Methods

    ConstrainYaw(Quaternion)

    Returns a rotation which only contains the yaw component of the given rotation

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

    The rotation we would like to constrain

    Returns
    Type Description
    Quaternion

    A yaw-only rotation which matches the input's yaw

    ConstrainYawPitch(Quaternion)

    Returns a rotation which only contains the yaw and pitch component of the given rotation

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

    The rotation we would like to constrain

    Returns
    Type Description
    Quaternion

    A yaw/pitch-only rotation which matches the input's yaw and pitch

    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX