IIntersectableWithRay Interface
Namespace: Stride.Core.MathematicsAssembly: Stride.Core.Mathematics.dll
Allows to determine intersections with a Ray.
public interface IIntersectableWithRay
| Name | Description | |
|---|---|---|
| Methods | ||
| Intersects(ref Ray) | Determines if there is an intersection between the current object and a Ray. |
|
| Intersects(ref Ray, out Vector3) | Determines if there is an intersection between the current object and a Ray. |
|
| Intersects(ref Ray, out Single) | Determines if there is an intersection between the current object and a Ray. |
|
Methods
Intersects(ref Ray)
Determines if there is an intersection between the current object and a Ray.
bool Intersects(ref Ray ray)
Parameters
| Type | Name | Description |
|---|---|---|
| Ray | ray | The ray to test. |
Returns
| Type | Description |
|---|---|
| System.Boolean | Whether the two objects intersected. |
Intersects(ref Ray, out Vector3)
Determines if there is an intersection between the current object and a Ray.
bool Intersects(ref Ray ray, out Vector3 point)
Parameters
| Type | Name | Description |
|---|---|---|
| Ray | ray | The ray to test. |
| Vector3 | point | When the method completes, contains the point of intersection, or Zero if there was no intersection. |
Returns
| Type | Description |
|---|---|
| System.Boolean | Whether the two objects intersected. |
Intersects(ref Ray, out Single)
Determines if there is an intersection between the current object and a Ray.
bool Intersects(ref Ray ray, out float distance)
Parameters
| Type | Name | Description |
|---|---|---|
| Ray | ray | The ray to test. |
| System.Single | distance | When the method completes, contains the distance of the intersection, or 0 if there was no intersection. |
Returns
| Type | Description |
|---|---|
| System.Boolean | Whether the two objects intersected. |