Raytrix Light Field SDK  4.0
Logo
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Rx::Net::Vector2D Struct Reference

Detailed Description

A 2-dimensional vector.

Public Member Functions

 Vector2D (double X, double Y)
 Constructor. More...
 
void Set (double X, double Y)
 Sets the coordinates of the vector. More...
 
virtual System::String^ ToString () override
 Convert this object into a string representation. More...
 

Static Public Member Functions

static double Distance (Vector2D vA, Vector2D vB)
 Calculates the distance between the two given vectors. More...
 
static double Length (Vector2D vA)
 Calculates the length of the given vector. More...
 
static Vector2D operator* (Vector2D vA, double dScalar)
 Multiplication operator. More...
 
static Vector2D operator* (double dScalar, Vector2D vA)
 Multiplication operator. More...
 
static Vector2D operator+ (Vector2D vA, Vector2D vB)
 Addition operator. More...
 
static Vector2D operator- (Vector2D vA, Vector2D vB)
 Subtraction operator. More...
 
static Vector2D operator/ (Vector2D vA, double dScalar)
 Division operator. More...
 
static bool operator== (Vector2D vA, Vector2D vB)
 Equality operator. More...
 

Public Attributes

double X
 The X coordinate. More...
 
double Y
 The Y coordinate. More...
 

Constructor & Destructor Documentation

Rx::Net::Vector2D::Vector2D ( double  X,
double  Y 
)
inline

Constructor.

Parameters
XThe X coordinate.
YThe Y coordinate.

Member Function Documentation

static double Rx::Net::Vector2D::Distance ( Vector2D  vA,
Vector2D  vB 
)
inlinestatic

Calculates the distance between the two given vectors.

Parameters
vAThe first vector.
vBThe second vector.
Returns
The distance.
static double Rx::Net::Vector2D::Length ( Vector2D  vA)
inlinestatic

Calculates the length of the given vector.

Parameters
vAThe vector.
Returns
The length.
static Vector2D Rx::Net::Vector2D::operator* ( Vector2D  vA,
double  dScalar 
)
inlinestatic

Multiplication operator.

Parameters
vAThe first value to multiply.
dScalarThe second value to multiply.
Returns
The result of the operation.
static Vector2D Rx::Net::Vector2D::operator* ( double  dScalar,
Vector2D  vA 
)
inlinestatic

Multiplication operator.

Parameters
dScalarThe first value to multiply.
vAThe second value to multiply.
Returns
The result of the operation.
static Vector2D Rx::Net::Vector2D::operator+ ( Vector2D  vA,
Vector2D  vB 
)
inlinestatic

Addition operator.

Parameters
vAThe first value.
vBA value to add to it.
Returns
The result of the operation.
static Vector2D Rx::Net::Vector2D::operator- ( Vector2D  vA,
Vector2D  vB 
)
inlinestatic

Subtraction operator.

Parameters
vAThe first value.
vBA value to subtract from it.
Returns
The result of the operation.
static Vector2D Rx::Net::Vector2D::operator/ ( Vector2D  vA,
double  dScalar 
)
inlinestatic

Division operator.

Parameters
vAThe numerator.
dScalarThe denominator.
Returns
The result of the operation.
static bool Rx::Net::Vector2D::operator== ( Vector2D  vA,
Vector2D  vB 
)
inlinestatic

Equality operator.

Parameters
vAThe first Value to compare.
vBThe second Value to compare.
Returns
True all components of the vector are equal.
void Rx::Net::Vector2D::Set ( double  X,
double  Y 
)
inline

Sets the coordinates of the vector.

Parameters
XThe X coordinate.
YThe Y coordinate.
virtual System::String ^ Rx::Net::Vector2D::ToString ( )
inlineoverridevirtual

Convert this object into a string representation.

Returns
This object as a string.

Member Data Documentation

double Rx::Net::Vector2D::X

The X coordinate.

double Rx::Net::Vector2D::Y

The Y coordinate.