docs.unity3d.com
    目次を表示する/隠す

    Class XRControllerState

    Represents the current state of the XRBaseController.

    Inheritance
    Object
    XRControllerState
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.XR.Interaction.Toolkit
    Syntax
    [Serializable]
    public class XRControllerState

    Constructors

    XRControllerState()

    Initializes and returns an instance of XRControllerState.

    Declaration
    public XRControllerState()

    XRControllerState(Double, Vector3, Quaternion, Boolean, Boolean, Boolean)

    (Deprecated) Initializes and returns an instance of XRControllerState.

    Declaration
    [Obsolete("This constructor has been deprecated. Use the constructors with the inputTrackingState parameter.")]
    public XRControllerState(double time, Vector3 position, Quaternion rotation, bool selectActive, bool activateActive, bool pressActive)
    Parameters
    Type Name Description
    Double time

    The time value for this controller.

    Vector3 position

    The position for this controller.

    Quaternion rotation

    The rotation for this controller.

    Boolean selectActive

    Whether select is active or not.

    Boolean activateActive

    Whether activate is active or not.

    Boolean pressActive

    Whether UI press is active or not.

    XRControllerState(Double, Vector3, Quaternion, InputTrackingState)

    Initializes and returns an instance of XRControllerState.

    Declaration
    protected XRControllerState(double time, Vector3 position, Quaternion rotation, InputTrackingState inputTrackingState)
    Parameters
    Type Name Description
    Double time

    The time value for this controller.

    Vector3 position

    The position for this controller.

    Quaternion rotation

    The rotation for this controller.

    InputTrackingState inputTrackingState

    The inputTrackingState for this controller.

    XRControllerState(Double, Vector3, Quaternion, InputTrackingState, Boolean, Boolean, Boolean)

    Initializes and returns an instance of XRControllerState.

    Declaration
    public XRControllerState(double time, Vector3 position, Quaternion rotation, InputTrackingState inputTrackingState, bool selectActive, bool activateActive, bool pressActive)
    Parameters
    Type Name Description
    Double time

    The time value for this controller.

    Vector3 position

    The position for this controller.

    Quaternion rotation

    The rotation for this controller.

    InputTrackingState inputTrackingState

    The inputTrackingState for this controller.

    Boolean selectActive

    Whether select is active or not.

    Boolean activateActive

    Whether activate is active or not.

    Boolean pressActive

    Whether UI press is active or not.

    XRControllerState(Double, Vector3, Quaternion, InputTrackingState, Boolean, Boolean, Boolean, Single, Single, Single)

    Initializes and returns an instance of XRControllerState.

    Declaration
    public XRControllerState(double time, Vector3 position, Quaternion rotation, InputTrackingState inputTrackingState, bool selectActive, bool activateActive, bool pressActive, float selectValue, float activateValue, float pressValue)
    Parameters
    Type Name Description
    Double time

    The time value for this controller.

    Vector3 position

    The position for this controller.

    Quaternion rotation

    The rotation for this controller.

    InputTrackingState inputTrackingState

    The inputTrackingState for this controller.

    Boolean selectActive

    Whether select is active or not.

    Boolean activateActive

    Whether activate is active or not.

    Boolean pressActive

    Whether UI press is active or not.

    Single selectValue

    The select value.

    Single activateValue

    The activate value.

    Single pressValue

    The UI press value.

    XRControllerState(XRControllerState)

    Initializes and returns an instance of XRControllerState.

    Declaration
    public XRControllerState(XRControllerState value)
    Parameters
    Type Name Description
    XRControllerState value

    The XRControllerState object used to create this object.

    Fields

    activateInteractionState

    The activate interaction state.

    Declaration
    public InteractionState activateInteractionState
    Field Value
    Type Description
    InteractionState

    inputTrackingState

    The input tracking state of the controller.

    Declaration
    public InputTrackingState inputTrackingState
    Field Value
    Type Description
    InputTrackingState

    position

    The position of the controller.

    Declaration
    public Vector3 position
    Field Value
    Type Description
    Vector3

    rotation

    The rotation of the controller.

    Declaration
    public Quaternion rotation
    Field Value
    Type Description
    Quaternion

    selectInteractionState

    The selection interaction state.

    Declaration
    public InteractionState selectInteractionState
    Field Value
    Type Description
    InteractionState

    time

    The time value for this controller.

    Declaration
    public double time
    Field Value
    Type Description
    Double

    uiPressInteractionState

    The UI press interaction state.

    Declaration
    public InteractionState uiPressInteractionState
    Field Value
    Type Description
    InteractionState

    Properties

    poseDataFlags

    (Deprecated) The pose data flags of the controller.

    Declaration
    [Obsolete("poseDataFlags has been deprecated. Use inputTrackingState instead.")]
    public PoseDataFlags poseDataFlags { get; set; }
    Property Value
    Type Description
    PoseDataFlags
    See Also
    inputTrackingState

    Methods

    ResetFrameDependentStates()

    Resets all the interaction states that are based on whether they occurred "this frame".

    Declaration
    public void ResetFrameDependentStates()
    See Also
    ResetFrameDependent()

    ResetInputs()

    (Deprecated) Resets all the interaction states that are based on whether they occurred "this frame".

    Declaration
    [Obsolete("ResetInputs has been renamed. Use ResetFrameDependentStates instead. (UnityUpgradable) -> ResetFrameDependentStates()")]
    public void ResetInputs()
    Remarks

    ResetInputs has been renamed. Use ResetFrameDependentStates() instead.

    ToString()

    Converts state data to a string.

    Declaration
    public override string ToString()
    Returns
    Type Description
    String

    A string representation.

    Overrides
    Object.ToString()
    トップに戻る
    Copyright © 2023 Unity Technologies — 商標と利用規約
    • 法律関連
    • プライバシーポリシー
    • クッキー
    • 私の個人情報を販売または共有しない
    • Your Privacy Choices (Cookie Settings)