Public Member Functions | |
void | Zero (void) |
Initialize the vector elements to zero. | |
void | One (void) |
Initialize the vector elements to 1.0f (Fixed) | |
Fixed32 | GetX (void) const |
Return the x component of the vector. | |
Fixed32 | GetY (void) const |
Return the y component of the vector. | |
Fixed32 | GetZ (void) const |
Return the z component of the vector. | |
void | SetX (Fixed32 fX) |
Set the x component of the vector. | |
void | SetY (Fixed32 fY) |
Set the y component of the vector. | |
void | SetZ (Fixed32 fZ) |
Set the z component of the vector. | |
void | Set (Fixed32 fX, Fixed32 fY, Fixed32 fZ) |
Initialize the vector elements to specific values,. | |
void | Set (const FixedVector3D_t *pInput) |
Copy a FixedVector3D_t. | |
void | Set (const Vector3D_t *pInput) |
Convert a floating point vector into fixed point vector. | |
void | SetAsInt (const Vector3D_t *pInput) |
Convert a floating point vector into an integer vector. | |
void | Negate (void) |
Negate a fixed vector. | |
void | Negate (const FixedVector3D_t *pInput) |
Negate and copy a vector. | |
void | Add (const FixedVector3D_t *pInput) |
Add two vectors. | |
void | Add (const FixedVector3D_t *pInput1, const FixedVector3D_t *pInput2) |
Add and copy two vectors. | |
void | Sub (const FixedVector3D_t *pInput) |
Subtract two vectors. | |
void | Sub (const FixedVector3D_t *pInput1, const FixedVector3D_t *pInput2) |
Subtract and copy two vectors. | |
Fixed32 | Dot (const FixedVector3D_t *pInput) const |
Perform a dot product. | |
void | Cross (const FixedVector3D_t *pInput1, const FixedVector3D_t *pInput2) |
Perform a cross product. | |
Public Attributes | |
Fixed32 | x |
X value for the 3D Vector. | |
Fixed32 | y |
Y value for the 3D Vector. | |
Fixed32 | z |
Z value for the 3D Vector. | |
3D Fixed32 vector.
This 12 byte structure contains 3 32-bit Fixed point values as a 3D vector.
void BURGER_API Burger::FixedVector3D_t::Add | ( | const FixedVector3D_t * | pInput | ) |
Add two vectors.
Perform a vector addition in the form of x += pInput->x, y+=pInput->y etc.
pInput | Pointer to a valid FixedVector3D_t |
void BURGER_API Burger::FixedVector3D_t::Add | ( | const FixedVector3D_t * | pInput1, |
const FixedVector3D_t * | pInput2 ) |
Add and copy two vectors.
Perform a vector addition in the form of x = pInput1->x+pInput2->x, y = pInput2->y+pInput2->y etc.
pInput1 | Pointer to a valid FixedVector3D_t |
pInput2 | Pointer to a valid FixedVector3D_t to add with |
void BURGER_API Burger::FixedVector3D_t::Cross | ( | const FixedVector3D_t * | pInput1, |
const FixedVector3D_t * | pInput2 ) |
Perform a cross product.
Perform a cross product between two vector and store the result in the *this value. The values are cached, so the *this pointer can be used as an input parameter without causing a problem.
pInput1 | Pointer to a valid FixedVector3D_t |
pInput2 | Pointer to a valid FixedVector3D_t to add with |
Fixed32 BURGER_API Burger::FixedVector3D_t::Dot | ( | const FixedVector3D_t * | pInput | ) | const |
Perform a dot product.
Perform a dot product with *this and the supplied vector.
pInput | Pointer to a valid FixedVector3D_t |
|
inline |
|
inline |
|
inline |
void BURGER_API Burger::FixedVector3D_t::Negate | ( | const FixedVector3D_t * | pInput | ) |
Negate and copy a vector.
Perform a negation on all three elements of a given vector and store the results.
pInput | Pointer to a valid FixedVector3D_t |
void BURGER_API Burger::FixedVector3D_t::Negate | ( | void | ) |
Negate a fixed vector.
Perform a negation on all three elements of the vector.
|
inline |
Initialize the vector elements to 1.0f (Fixed)
Fills in all of the entries with zero, thereby initializing the structure to a known state.
|
inline |
Copy a FixedVector3D_t.
Make a copy of a FixedVector3D_t
pInput | Valid pointer to a FixedVector3D_t structure to copy |
void BURGER_API Burger::FixedVector3D_t::Set | ( | const Vector3D_t * | pInput | ) |
Convert a floating point vector into fixed point vector.
Using round to nearest, convert a Vector3D_t 's data into a FixedVector3D_t. Saturation is performed. NaN and Infinity will yield undefined results.
pInput | Pointer to an initialized Vector3D_t structure. |
Initialize the vector elements to specific values,.
Given the new values for x,y and z, store them into the structure.
fX | The new x component to store in the vector. |
fY | The new y component to store in the vector. |
fZ | The new z component to store in the vector. |
void BURGER_API Burger::FixedVector3D_t::SetAsInt | ( | const Vector3D_t * | pInput | ) |
Convert a floating point vector into an integer vector.
Using round to nearest, convert a Vector3D_t 's data into a FixedVector3D_t and the conversion will place integer values in the members instead of performing the float->Fixed32 conversion. Saturation is performed. NaN and Infinity will yield undefined results.
pInput | Pointer to an initialized Vector3D_t structure. |
|
inline |
Set the x component of the vector.
fX | The new x component of the vector. |
|
inline |
Set the y component of the vector.
fY | The new y component of the vector. |
|
inline |
Set the z component of the vector.
fZ | The new z component of the vector. |
void BURGER_API Burger::FixedVector3D_t::Sub | ( | const FixedVector3D_t * | pInput | ) |
Subtract two vectors.
Perform a vector subtraction in the form of x -= pInput->x, y-=pInput->y etc.
pInput | Pointer to a valid FixedVector3D_t |
void BURGER_API Burger::FixedVector3D_t::Sub | ( | const FixedVector3D_t * | pInput1, |
const FixedVector3D_t * | pInput2 ) |
Subtract and copy two vectors.
Perform a vector subtraction in the form of x = pInput1->x-pInput2->x, y = pInput2->y-pInput2->y etc.
pInput1 | Pointer to a valid FixedVector3D_t |
pInput2 | Pointer to a valid FixedVector3D_t to subtract from |
|
inline |
Initialize the vector elements to zero.
Fills in all of the entries with zero, thereby initializing the structure to a known state.
Fixed32 Burger::FixedVector3D_t::x |
X value for the 3D Vector.
Fixed32 Burger::FixedVector3D_t::y |
Y value for the 3D Vector.
Fixed32 Burger::FixedVector3D_t::z |
Z value for the 3D Vector.