Space Engineers
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
VRageMath.Ray Struct Reference

Defines a ray. More...

Inheritance diagram for VRageMath.Ray:

Public Member Functions

 Ray (Vector3 position, Vector3 direction)
 Creates a new instance of Ray. More...
 
bool Equals (Ray other)
 Determines whether the specified Ray is equal to the current Ray. More...
 
override bool Equals (object obj)
 Determines whether two instances of Ray are equal. More...
 
override int GetHashCode ()
 Gets the hash code for this instance. More...
 
override string ToString ()
 Returns a String that represents the current Ray. More...
 
float Intersects (BoundingBox box)
 Checks whether the Ray intersects a specified BoundingBox. More...
 
void Intersects (ref BoundingBox box, out float?result)
 Checks whether the current Ray intersects a BoundingBox. More...
 
float Intersects (BoundingFrustum frustum)
 Checks whether the Ray intersects a specified BoundingFrustum. More...
 
float Intersects (Plane plane)
 Determines whether this Ray intersects a specified Plane. More...
 
void Intersects (ref Plane plane, out float?result)
 Determines whether this Ray intersects a specified Plane. More...
 
float Intersects (BoundingSphere sphere)
 Checks whether the Ray intersects a specified BoundingSphere. More...
 
void Intersects (ref BoundingSphere sphere, out float?result)
 Checks whether the current Ray intersects a BoundingSphere. More...
 

Static Public Member Functions

static bool operator== (Ray a, Ray b)
 Determines whether two instances of Ray are equal. More...
 
static bool operator!= (Ray a, Ray b)
 Determines whether two instances of Ray are not equal. More...
 

Public Attributes

Vector3 Position
 Specifies the starting point of the Ray. More...
 
Vector3 Direction
 Unit vector specifying the direction the Ray is pointing. More...
 

Detailed Description

Defines a ray.

Definition at line 10 of file Ray.cs.

Constructor & Destructor Documentation

VRageMath.Ray.Ray ( Vector3  position,
Vector3  direction 
)
inline

Creates a new instance of Ray.

Parameters
positionThe starting point of the Ray.
directionUnit vector describing the direction of the Ray.

Definition at line 25 of file Ray.cs.

Member Function Documentation

bool VRageMath.Ray.Equals ( Ray  other)
inline

Determines whether the specified Ray is equal to the current Ray.

Parameters
otherThe Ray to compare with the current Ray.

Definition at line 59 of file Ray.cs.

override bool VRageMath.Ray.Equals ( object  obj)
inline

Determines whether two instances of Ray are equal.

Parameters
objThe Object to compare with the current Ray.

Definition at line 71 of file Ray.cs.

override int VRageMath.Ray.GetHashCode ( )
inline

Gets the hash code for this instance.

Definition at line 82 of file Ray.cs.

float VRageMath.Ray.Intersects ( BoundingBox  box)
inline

Checks whether the Ray intersects a specified BoundingBox.

Parameters
boxThe BoundingBox to check for intersection with the Ray.

Definition at line 103 of file Ray.cs.

void VRageMath.Ray.Intersects ( ref BoundingBox  box,
out float?  result 
)
inline

Checks whether the current Ray intersects a BoundingBox.

Parameters
boxThe BoundingBox to check for intersection with.
result[OutAttribute] Distance at which the ray intersects the BoundingBox or null if there is no intersection.

Definition at line 112 of file Ray.cs.

float VRageMath.Ray.Intersects ( BoundingFrustum  frustum)
inline

Checks whether the Ray intersects a specified BoundingFrustum.

Parameters
frustumThe BoundingFrustum to check for intersection with the Ray.

Definition at line 121 of file Ray.cs.

float VRageMath.Ray.Intersects ( Plane  plane)
inline

Determines whether this Ray intersects a specified Plane.

Parameters
planeThe Plane with which to calculate this Ray's intersection.

Definition at line 133 of file Ray.cs.

void VRageMath.Ray.Intersects ( ref Plane  plane,
out float?  result 
)
inline

Determines whether this Ray intersects a specified Plane.

Parameters
planeThe Plane with which to calculate this Ray's intersection.
result[OutAttribute] The distance at which this Ray intersects the specified Plane, or null if there is no intersection.

Definition at line 153 of file Ray.cs.

float VRageMath.Ray.Intersects ( BoundingSphere  sphere)
inline

Checks whether the Ray intersects a specified BoundingSphere.

Parameters
sphereThe BoundingSphere to check for intersection with the Ray.

Definition at line 182 of file Ray.cs.

void VRageMath.Ray.Intersects ( ref BoundingSphere  sphere,
out float?  result 
)
inline

Checks whether the current Ray intersects a BoundingSphere.

Parameters
sphereThe BoundingSphere to check for intersection with.
result[OutAttribute] Distance at which the ray intersects the BoundingSphere or null if there is no intersection.

Definition at line 205 of file Ray.cs.

static bool VRageMath.Ray.operator!= ( Ray  a,
Ray  b 
)
inlinestatic

Determines whether two instances of Ray are not equal.

Parameters
aThe object to the left of the inequality operator.
bThe object to the right of the inequality operator.

Definition at line 47 of file Ray.cs.

static bool VRageMath.Ray.operator== ( Ray  a,
Ray  b 
)
inlinestatic

Determines whether two instances of Ray are equal.

Parameters
aThe object to the left of the equality operator.
bThe object to the right of the equality operator.

Definition at line 35 of file Ray.cs.

override string VRageMath.Ray.ToString ( )
inline

Returns a String that represents the current Ray.

Definition at line 90 of file Ray.cs.

Member Data Documentation

Vector3 VRageMath.Ray.Direction

Unit vector specifying the direction the Ray is pointing.

Definition at line 19 of file Ray.cs.

Vector3 VRageMath.Ray.Position

Specifies the starting point of the Ray.

Definition at line 15 of file Ray.cs.


The documentation for this struct was generated from the following file: