Base::Vector2d Class Reference

The vector class for 2D calculations. More...

`#include <Tools2D.h>`

## Public Member Functions

double Angle () const

double Distance (const Vector2d &v) const

double GetAngle (const Vector2d &v) const

bool IsEqual (const Vector2d &v, double tolerance=0.0) const

bool IsNull (double tolerance=0.0) const

double Length () const

Vector2dNegate ()

Vector2dNormalize ()

double operator* (const Vector2d &v) const

Vector2d operator* (double c) const

Vector2doperator*= (double c)

Vector2d operator+ (const Vector2d &v) const

Vector2d operator+ (void) const

Vector2doperator+= (const Vector2d &v)

Vector2d operator- (const Vector2d &v) const

Vector2d operator- (void) const

Vector2doperator-= (const Vector2d &v)

Vector2d operator/ (double c) const

Vector2doperator/= (double c)

Vector2doperator= (const Vector2d &v)

bool operator== (const Vector2d &v) const

Vector2d Perpendicular (bool clockwise=false) const

void ProjectToLine (const Vector2d &point, const Vector2d &line)

Vector2dRotate (double angle)

Vector2dScale (double factor)

Vector2dSet (double x, double y)

double Sqr () const

Vector2d ()
INLINES. More...

Vector2d (const Vector2d &v)

Vector2d (double x, double y)

Vector2d (float x, float y)

## Static Public Member Functions

static Vector2d FromPolar (double r, double fi)

double x

double y

## Detailed Description

The vector class for 2D calculations.

## ◆ Vector2d() [1/4]

 Base::Vector2d::Vector2d ( )

## ◆ Vector2d() [2/4]

 Base::Vector2d::Vector2d ( float x, float y )

## ◆ Vector2d() [3/4]

 Base::Vector2d::Vector2d ( double x, double y )

## ◆ Vector2d() [4/4]

 Base::Vector2d::Vector2d ( const Vector2d & v )

## ◆ Angle()

 double Base::Vector2d::Angle ( ) const

## ◆ Distance()

 double Base::Vector2d::Distance ( const Vector2d & v ) const

## ◆ FromPolar()

 Vector2d Base::Vector2d::FromPolar ( double r, double fi )
static

## ◆ GetAngle()

 double Vector2d::GetAngle ( const Vector2d & v ) const

## ◆ IsEqual()

 bool Base::Vector2d::IsEqual ( const Vector2d & v, double tolerance = `0.0` ) const

## ◆ IsNull()

 bool Base::Vector2d::IsNull ( double tolerance = `0.0` ) const

## ◆ Negate()

 Vector2d & Base::Vector2d::Negate ( )

References x, and y.

## ◆ Normalize()

 Vector2d & Base::Vector2d::Normalize ( )

## ◆ operator*() [1/2]

 double Base::Vector2d::operator* ( const Vector2d & v ) const

References x.

## ◆ operator*() [2/2]

 Vector2d Base::Vector2d::operator* ( double c ) const

References Vector2d().

## ◆ operator*=()

 Vector2d & Base::Vector2d::operator*= ( double c )

## ◆ operator+() [1/2]

 Vector2d Base::Vector2d::operator+ ( const Vector2d & v ) const

References Vector2d().

## ◆ operator+() [2/2]

 Vector2d Base::Vector2d::operator+ ( void ) const

References Vector2d().

## ◆ operator+=()

 Vector2d & Base::Vector2d::operator+= ( const Vector2d & v )

References x.

## ◆ operator-() [1/2]

 Vector2d Base::Vector2d::operator- ( const Vector2d & v ) const

References Vector2d().

## ◆ operator-() [2/2]

 Vector2d Base::Vector2d::operator- ( void ) const

References Vector2d().

## ◆ operator-=()

 Vector2d & Base::Vector2d::operator-= ( const Vector2d & v )

References x.

## ◆ operator/()

 Vector2d Base::Vector2d::operator/ ( double c ) const

References Vector2d().

## ◆ operator/=()

 Vector2d & Base::Vector2d::operator/= ( double c )

## ◆ operator=()

 Vector2d & Base::Vector2d::operator= ( const Vector2d & v )

References x.

## ◆ operator==()

 bool Base::Vector2d::operator== ( const Vector2d & v ) const

## ◆ Perpendicular()

 Vector2d Base::Vector2d::Perpendicular ( bool clockwise = `false` ) const

References Vector2d().

## ◆ ProjectToLine()

 void Vector2d::ProjectToLine ( const Vector2d & point, const Vector2d & line )

## ◆ Rotate()

 Vector2d & Base::Vector2d::Rotate ( double angle )

References x.

## ◆ Scale()

 Vector2d & Base::Vector2d::Scale ( double factor )

## ◆ Set()

 Vector2d & Base::Vector2d::Set ( double x, double y )

References x, and y.

## ◆ Sqr()

 double Base::Vector2d::Sqr ( ) const

References y.

## ◆ y

The documentation for this class was generated from the following files: