9 #ifndef _LIBALMATH_ALMATH_TYPES_ALPOSITION2D_H_
10 #define _LIBALMATH_ALMATH_TYPES_ALPOSITION2D_H_
237 const float& pEpsilon=0.0001f)
const;
286 void toVector(std::vector<float>& pReturnVector)
const;
287 std::vector<float> toVector(
void)
const;
301 const Position2D& pPos1);
315 const Position2D& pPos1,
316 const Position2D& pPos2);
330 const Position2D& pPos1,
331 const Position2D& pPos2);
343 float norm(
const Position2D& pPos);
355 Position2D
normalize(
const Position2D& pPos);
368 const Position2D& pPos1,
369 const Position2D& pPos2);
383 const Position2D& pPos1,
384 const Position2D& pPos2);
397 const Position2D& pPos1,
398 const Position2D& pPos2,
403 #endif // _LIBALMATH_ALMATH_TYPES_ALPOSITION2D_H_
static Position2D fromPolarCoordinates(const float pRadius, const float pAngle)
Build a Position2D from polar coordinates.
Position2D normalize() const
Normalize the actual Position2D.
float distanceSquared(const Position2D &pPos1, const Position2D &pPos2)
Compute the squared distance between two Position2D.
void crossProduct(const Position2D &pPos1, const Position2D &pPos2, float &pRes)
Compute the cross Product of two Position2D.
Position2D operator+(void) const
Overloading of operator + for Position2D.
float distance(const Position2D &pPos2) const
Compute the distance between the actual Position2D and the one give in argument.
float dotProduct(const Position2D &pPos2) const
Compute the dot Product between the actual Position2D and the one give in argument.
float norm(const Position2D &pPos)
Compute the norm of a Position2D.
bool operator==(const Position2D &pPos2) const
Overloading of operator == for Position2D.
Position2D & operator/=(float pVal)
Overloading of operator /= for Position2D.
bool isNear(const Position2D &pPos2, const float &pEpsilon=0.0001f) const
Check if the actual Position2D is near the one give in argument.
Position2D operator*(float pVal) const
Overloading of operator * for Position2D.
Position2D()
Create a Position2D initialized with 0.0f.
float norm() const
Compute the norm of the actual Position2D.
Position2D normalize(const Position2D &pPos)
Normalize a Position2D.
Position2D & operator+=(const Position2D &pPos2)
Overloading of operator += for Position2D.
Position3D operator*(const Rotation &pRot, const Position3D &pPos)
Overloading of operator * between Rotation and Position3D:
float distance(const Position2D &pPos1, const Position2D &pPos2)
Compute the distance between two Position2D :
Position2D operator/(float pVal) const
Overloading of operator / for Position2D.
Position2D operator-() const
Overloading of operator - for Position2D.
Position2D & operator*=(float pVal)
Overloading of operator *= for Position2D.
Position2D & operator-=(const Position2D &pPos2)
Overloading of operator -= for Position2D.
float getAngle() const
Return the angular direction of a Position2D.
bool operator!=(const Position2D &pPos2) const
Overloading of operator != for Position2D.
float crossProduct(const Position2D &pPos2) const
Compute the cross Product between the actual Position2D and the one give in argument.
Create and play with a Position2D.
float distanceSquared(const Position2D &pPos2) const
Compute the squared distance between the actual Position2D and the one give in argument.