#include <FMVector3.h>
Public Member Functions | |
FMVector3 () | |
Creates an empty FMVector3. | |
FMVector3 (float _x, float _y, float _z) | |
Creates the FMVector3 with the coordinates given. | |
FMVector3 (const float *source, uint32 startIndex=0) | |
Creates the FMVector3 from a list of floats . | |
float | LengthSquared () const |
Get the squared length. | |
float | Length () const |
Retrieves the length of the vector. | |
void | NormalizeIt () |
Normalize this FMVector3. | |
FMVector3 | Normalize () const |
Get a normalized FMVector3 with the same direction as this FMVector3. | |
void | Project (const FMVector3 &unto) |
Project this FMVector3 onto another FMVector3. | |
FMVector3 | Projected (const FMVector3 &unto) |
Get the projection of this FMVector3 onto another FMVector3. | |
operator float * () | |
Get this FMVector3 as an array of floats . | |
operator const float * () const | |
Get this FMVector3 as an array of floats . | |
FMVector3 & | operator= (const float *v) |
Assign this FMVector3 to the given float array. | |
void | ComponentMinimum (const FMVector3 &min) |
Update each component of this FMVector to the minimum of two FMVector3s. | |
void | ComponentMaximum (const FMVector3 &max) |
Update each component of this FMVector to the maximum of two FMVector3s. | |
void | ComponentClamp (const FMVector3 &min, const FMVector3 &max) |
Clamp each component of this FMVector by the corresponding components in the specified min and max FMVector3. | |
Public Attributes | |
float | x |
The first coordinate. | |
float | y |
The second coordinate. | |
float | z |
The third coordinate. | |
Static Public Attributes | |
static const FMVector3 | XAxis |
The FMVector3 representing the x axis. | |
static const FMVector3 | YAxis |
The FMVector3 representing the y axis. | |
static const FMVector3 | ZAxis |
The FMVector3 representing the z axis. | |
static const FMVector3 | Zero |
The FMVector3 representing zero. | |
static const FMVector3 | Origin |
The FMVector3 representing the origin. |
Simple, non-optimized vector class: * is the dot-product, ^ is the cross-product.
|
Creates the FMVector3 with the coordinates given.
|
|
Creates the FMVector3 from a list of
It takes the first 3
|
|
Clamp each component of this FMVector by the corresponding components in the specified min and max FMVector3. Clamp refers to setting a value within a given range. If the value is lower than the minimum of the range, it is set to the minimum; same for the maximum.
|
|
Update each component of this FMVector to the maximum of two FMVector3s. Updates each of the three components to be the maximum of the current value and that of the corresponding value of the given FMVector3.
|
|
Update each component of this FMVector to the minimum of two FMVector3s. Updates each of the three components to be the minimum of the current value and that of the corresponding value of the given FMVector3.
|
|
Retrieves the length of the vector.
|
|
Get the squared length.
|
|
Get a normalized FMVector3 with the same direction as this FMVector3.
|
|
Get this FMVector3 as an array of
|
|
Get this FMVector3 as an array of
|
|
Assign this FMVector3 to the given float array.
Assigns each coordinate of this FMVector3 to the elements in the
|
|
Project this FMVector3 onto another FMVector3.
|
|
Get the projection of this FMVector3 onto another FMVector3.
|