This represents a line placed in 3D space and is used with spacial queries. More...
#include <ray.h>
Public Types | |
typedef std::pair< Boolean, Ray > | GeometryRayTestResult |
This is a type used for the return of a ray intersection test. More... | |
typedef std::pair< Boolean, Vector3 > | PlaneRayTestResult |
This is a type used for the ray intersection tests performed on Planes. More... | |
Public Member Functions | |
Ray () | |
Default constructor. More... | |
Ray (const Ray &Other) | |
Copy constructor. More... | |
Ray (const Vector3 &To) | |
Destination constructor. More... | |
Ray (const Vector3 &From, const Vector3 &To) | |
Descriptive constructor. More... | |
Ray (const Ogre::Ray &InternalRay) | |
Internal constructor. More... | |
~Ray () | |
Class destructor. | |
void | ExtractOgreRay (const Ogre::Ray &InternalRay) |
Changes this Ray to match the Ogre Ray. More... | |
Vector3 | GetDirection () const |
Gets the normal of this ray. More... | |
Ray | GetNormal () const |
Gets a copy of this ray with a unit length of 1. More... | |
Ogre::Ray | GetOgreRay () const |
Gets an Ogre::Ray that contains this Rays information. More... | |
PlaneRayTestResult | Intersects (const Plane &ToCheck) const |
Checks to see if this ray intersects a plane. More... | |
GeometryRayTestResult | Intersects (const Sphere &ToCheck) const |
Checks to see if this ray intersects a sphere. More... | |
GeometryRayTestResult | Intersects (const AxisAlignedBox &ToCheck) const |
Checks to see if this ray intersects an AABB. More... | |
Real | Length () const |
Measures the distance of this ray. More... | |
Ray & | Normalize () |
Reduces the length of this ray to 1 unit. More... | |
Boolean | operator!= (const Ray &Other) const |
Inequality operator. More... | |
Ray | operator* (const Real Factor) const |
Gets a Ray with a length longer than this one by the specified factor. More... | |
Ray & | operator*= (const Real Factor) |
Increases the length of this Ray by the factor provided. More... | |
Ray | operator/ (const Real Factor) const |
Gets a Ray with a length shorter than this one by the specified factor. More... | |
Ray & | operator/= (const Real Factor) |
Decreases the length of this Ray by the factor provided. More... | |
void | operator= (const Ray &Other) |
Assignment operator. More... | |
Boolean | operator== (const Ray &Other) const |
Equality operator. More... | |
void | ProtoDeSerialize (const XML::Node &SelfRoot) |
Take the data stored in an XML Node and overwrite this object with it. More... | |
void | ProtoSerialize (XML::Node &ParentNode) const |
Convert this class to an XML::Node ready for serialization. More... | |
Static Public Member Functions | |
static String | GetSerializableName () |
Get the name of the the XML tag the proxy class will leave behind as its instances are serialized. More... | |
Public Attributes | |
Vector3 | Destination |
The direction of this ray or end point of this ray depending on mode. | |
Vector3 | Origin |
The origin point of the Vector. | |
This represents a line placed in 3D space and is used with spacial queries.
typedef std::pair<Boolean,Ray> Mezzanine::Ray::GeometryRayTestResult |
typedef std::pair<Boolean,Vector3> Mezzanine::Ray::PlaneRayTestResult |
Mezzanine::Ray::Ray | ( | ) |
Mezzanine::Ray::Ray | ( | const Ray & | Other) |
Mezzanine::Ray::Ray | ( | const Vector3 & | To) |
|
explicit |
void Mezzanine::Ray::ExtractOgreRay | ( | const Ogre::Ray & | InternalRay) |
Vector3 Mezzanine::Ray::GetDirection | ( | ) | const |
Ray Mezzanine::Ray::GetNormal | ( | ) | const |
Ogre::Ray Mezzanine::Ray::GetOgreRay | ( | ) | const |
|
static |
Ray::PlaneRayTestResult Mezzanine::Ray::Intersects | ( | const Plane & | ToCheck) | const |
Ray::GeometryRayTestResult Mezzanine::Ray::Intersects | ( | const Sphere & | ToCheck) | const |
Ray::GeometryRayTestResult Mezzanine::Ray::Intersects | ( | const AxisAlignedBox & | ToCheck) | const |
Real Mezzanine::Ray::Length | ( | ) | const |
Ray & Mezzanine::Ray::Normalize | ( | ) |
Boolean Mezzanine::Ray::operator!= | ( | const Ray & | Other) | const |
void Mezzanine::Ray::operator= | ( | const Ray & | Other) |
Boolean Mezzanine::Ray::operator== | ( | const Ray & | Other) | const |
void Mezzanine::Ray::ProtoDeSerialize | ( | const XML::Node & | SelfRoot) |
void Mezzanine::Ray::ProtoSerialize | ( | XML::Node & | ParentNode) | const |