Create and play with a Velocity3D. More...
#include <alvelocity3d.h>
Public Member Functions | |
| Velocity3D () | |
| Create a Velocity3D initialize with 0.0f. | |
| Velocity3D (float pInit) | |
| Create a Velocity3D initialize with the same float. | |
| Velocity3D (float pXd, float pYd, float pZd) | |
| Create a Velocity3D initialize with explicit value. | |
| Velocity3D (const std::vector< float > &pFloats) | |
| Create a Velocity3D with an std::vector. | |
| Velocity3D | operator+ (const Velocity3D &pVel2) const |
| Overloading of operator + for Velocity3D. | |
| Velocity3D | operator- (const Velocity3D &pVel2) const |
| Overloading of operator - for Velocity3D. | |
| Velocity3D | operator+ () const |
| Overloading of operator + for Velocity3D. | |
| Velocity3D | operator- () const |
| Overloading of operator - for Velocity3D. | |
| Velocity3D & | operator+= (const Velocity3D &pVel2) |
| Overloading of operator += for Velocity3D. | |
| Velocity3D & | operator-= (const Velocity3D &pVel2) |
| Overloading of operator -= for Velocity3D. | |
| bool | operator== (const Velocity3D &pVel2) const |
| Overloading of operator == for Velocity3D. | |
| bool | operator!= (const Velocity3D &pVel2) const |
| Overloading of operator != for Velocity3D. | |
| Velocity3D | operator* (const float pVal) const |
| Overloading of operator * for Velocity3D. | |
| Velocity3D | operator/ (const float pVal) const |
| Overloading of operator / for Velocity3D. | |
| Velocity3D & | operator*= (const float pVal) |
| Overloading of operator *= for Velocity3D. | |
| Velocity3D & | operator/= (const float pVal) |
| Overloading of operator /= for Velocity3D. | |
| bool | isNear (const Velocity3D &pVel2, const float &pEpsilon=0.0001f) const |
| Check if the actual Velocity3D is Near the one given in argument. | |
| float | norm () const |
| Compute the norm of the actual Velocity3D: | |
| Velocity3D | normalize () const |
| Normalize the actual Velocity3D: | |
| std::vector< float > | toVector () const |
| Return the Velocity3D as a vector of float [xd, yd, zd]. | |
Public Attributes | |
| float | xd |
| float | yd |
| float | zd |
Create and play with a Velocity3D.
A Velocity3D is just defined by xd, yd and zd.
Definition at line 23 of file alvelocity3d.h.
Create a Velocity3D initialize with 0.0f.
| AL::Math::Velocity3D::Velocity3D | ( | float | pInit | ) | [explicit] |
Create a Velocity3D initialize with the same float.
| pInit | the float value for each member |
| AL::Math::Velocity3D::Velocity3D | ( | float | pXd, |
| float | pYd, | ||
| float | pZd | ||
| ) |
Create a Velocity3D initialize with explicit value.
| pXd | the float value for xd |
| pYd | the float value for yd |
| pZd | the float value for zd |
| AL::Math::Velocity3D::Velocity3D | ( | const std::vector< float > & | pFloats | ) |
Create a Velocity3D with an std::vector.
| pFloats | An std::vector<float> of size 3 for respectively: xd, yd, zd |
| bool AL::Math::Velocity3D::isNear | ( | const Velocity3D & | pVel2, |
| const float & | pEpsilon = 0.0001f |
||
| ) | const |
Check if the actual Velocity3D is Near the one given in argument.
| pVel2 | the second Velocity3D |
| pEpsilon | an optional epsilon distance |
| float AL::Math::Velocity3D::norm | ( | ) | const |
| Velocity3D AL::Math::Velocity3D::normalize | ( | ) | const |
| bool AL::Math::Velocity3D::operator!= | ( | const Velocity3D & | pVel2 | ) | const |
Overloading of operator != for Velocity3D.
| pVel2 | the second Velocity3D |
| Velocity3D AL::Math::Velocity3D::operator* | ( | const float | pVal | ) | const |
Overloading of operator * for Velocity3D.
| pVal | the float factor |
| Velocity3D& AL::Math::Velocity3D::operator*= | ( | const float | pVal | ) |
Overloading of operator *= for Velocity3D.
| pVal | the float factor |
| Velocity3D AL::Math::Velocity3D::operator+ | ( | const Velocity3D & | pVel2 | ) | const |
Overloading of operator + for Velocity3D.
| pVel2 | the second Velocity3D |
| Velocity3D AL::Math::Velocity3D::operator+ | ( | ) | const |
Overloading of operator + for Velocity3D.
| Velocity3D& AL::Math::Velocity3D::operator+= | ( | const Velocity3D & | pVel2 | ) |
Overloading of operator += for Velocity3D.
| pVel2 | the second Velocity3D |
| Velocity3D AL::Math::Velocity3D::operator- | ( | const Velocity3D & | pVel2 | ) | const |
Overloading of operator - for Velocity3D.
| pVel2 | the second Velocity3D |
| Velocity3D AL::Math::Velocity3D::operator- | ( | ) | const |
Overloading of operator - for Velocity3D.
| Velocity3D& AL::Math::Velocity3D::operator-= | ( | const Velocity3D & | pVel2 | ) |
Overloading of operator -= for Velocity3D.
| pVel2 | the second Velocity3D |
| Velocity3D AL::Math::Velocity3D::operator/ | ( | const float | pVal | ) | const |
Overloading of operator / for Velocity3D.
| pVal | the float factor |
| Velocity3D& AL::Math::Velocity3D::operator/= | ( | const float | pVal | ) |
Overloading of operator /= for Velocity3D.
| pVal | the float factor |
| bool AL::Math::Velocity3D::operator== | ( | const Velocity3D & | pVel2 | ) | const |
Overloading of operator == for Velocity3D.
| pVel2 | the second Velocity3D |
| std::vector<float> AL::Math::Velocity3D::toVector | ( | ) | const |
Return the Velocity3D as a vector of float [xd, yd, zd].
| float AL::Math::Velocity3D::xd |
Definition at line 25 of file alvelocity3d.h.
| float AL::Math::Velocity3D::yd |
Definition at line 27 of file alvelocity3d.h.
| float AL::Math::Velocity3D::zd |
Definition at line 29 of file alvelocity3d.h.