docs.unity3d.com
    Show / Hide Table of Contents

    Interface IXRInteractionStrengthInteractable

    An interface that represents an Interactable component which can express an interaction strength amount, which is a normalized value [0.0, 1.0] that describes the strength of selection.

    Inherited Members
    IXRInteractable.registered
    IXRInteractable.unregistered
    IXRInteractable.interactionLayers
    IXRInteractable.colliders
    IXRInteractable.transform
    IXRInteractable.GetAttachTransform(IXRInteractor)
    IXRInteractable.OnRegistered(InteractableRegisteredEventArgs)
    IXRInteractable.OnUnregistered(InteractableUnregisteredEventArgs)
    IXRInteractable.ProcessInteractable(XRInteractionUpdateOrder.UpdatePhase)
    IXRInteractable.GetDistanceSqrToInteractor(IXRInteractor)
    Namespace: UnityEngine.XR.Interaction.Toolkit
    Syntax
    public interface IXRInteractionStrengthInteractable : IXRInteractable
    Remarks

    For interactors that use motion controller input, this is typically based on the analog trigger or grip press amount. It can also be based on a poke amount for how deep a poke interactor has pressed into an interactable.

    Properties

    largestInteractionStrength

    The largest interaction strength value of all interactors hovering or selecting this interactable.

    Declaration
    IReadOnlyBindableVariable<float> largestInteractionStrength { get; }
    Property Value
    Type Description
    IReadOnlyBindableVariable<Single>

    Methods

    GetInteractionStrength(IXRInteractor)

    Gets the interaction strength between the given interactor and this interactable.

    Declaration
    float GetInteractionStrength(IXRInteractor interactor)
    Parameters
    Type Name Description
    IXRInteractor interactor

    The specific interactor to get the interaction strength between.

    Returns
    Type Description
    Single

    Returns a value [0.0, 1.0] of the interaction strength.

    ProcessInteractionStrength(XRInteractionUpdateOrder.UpdatePhase)

    The XRInteractionManager calls this method to signal to update the interaction strength.

    Declaration
    void ProcessInteractionStrength(XRInteractionUpdateOrder.UpdatePhase updatePhase)
    Parameters
    Type Name Description
    XRInteractionUpdateOrder.UpdatePhase updatePhase

    The update phase during which this method is called.

    See Also
    XRInteractionUpdateOrder.UpdatePhase

    See Also

    IXRInteractionStrengthInteractor
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023