Enum NearFarInteractor.NearCasterSortingStrategy
Enum used to determine the strategy used to compute the the distance used to sort valid targets discovered by the near interaction caster.
Namespace: UnityEngine.XR.Interaction.Toolkit.Interactors
Assembly: Unity.XR.Interaction.Toolkit.dll
Syntax
public enum NearFarInteractor.NearCasterSortingStrategy
Fields
Name | Description |
---|---|
ClosestPointOnCollider | Sorting is performed based on the square distance between the interactor's attach transform world position and the closest point of that position on the interactable's collider. This is an expensive sorting strategy and should only be used if there is a need for high fidelity disambiguation between interactables that are very close to each other. |
InteractableBased | Sorting is performed based on the interactable's defined sorting strategy. The callstack used here is the most extensive one, and performance will depend on the implementation of the interactable's sorting strategy, which defaults to being collider based. |
None | No sorting should be performed. |
SquareDistance | Sorting is performed based on the square distance between the interactor and interactable attach transform world positions. This is the most efficient sorting strategy. |