Struct ARRaycastHit
Represents the result of a raycast intersection with a trackable.
Inherited Members
Namespace: UnityEngine .XR.ARFoundation
Assembly: solution.dll
Syntax
public struct ARRaycastHit : IEquatable<ARRaycastHit>, IComparable<ARRaycastHit>
Constructors
Name | Description |
---|---|
ARRaycast |
Constructor invoked by Raycast(Vector2, List<ARRaycast |
ARRaycast |
Constructor invoked by Raycast(Vector2, List<ARRaycast |
Properties
Name | Description |
---|---|
distance | The distance, in Unity world space, from the ray origin to the intersection point. |
hit |
The type of trackable hit by the raycast. |
pose | The |
session |
The distance, in local (session) space, from the ray origin to the intersection point. |
session |
The |
trackable | The ARTrackable that this raycast hit, or |
trackable |
The session-unique identifier for the trackable that was hit. |
Methods
Name | Description |
---|---|
Compare |
Used for sorting two raycast hits by distance. Uses CompareTo on the raycasts' distance properties. |
Equals(object) | Tests for equality. |
Equals(ARRaycast |
Tests for equality. |
Get |
Generates a hash suitable for use with containers like |
Operators
Name | Description |
---|---|
operator ==(ARRaycast |
Tests for equality. Same as Equals(ARRaycast |
operator !=(ARRaycast |
Tests for inequality. Same as |