AR + GPS Location  3.0.0
All Classes Namespaces Functions Variables Properties Events Pages
ARLocation.DVector2 Struct Reference

Public Member Functions

DVector2 Clone ()
 
 DVector2 (double x=0.0, double y=0.0)
 Initializes a new instance of the T:DVector2 struct. More...
 
Vector2 toVector2 ()
 Converts to a Vector2. More...
 
bool Equals (DVector2 v, double e=0.00005)
 Equals the specified v and e. More...
 
void Normalize ()
 Normalize this instance. More...
 
void Set (double newX=0.0, double newY=0.0)
 Set the specified x and y. More...
 
override string ToString ()
 Returns a T:System.String that represents the current T:DVector2. More...
 

Static Public Member Functions

static double Dot (DVector2 a, DVector2 b)
 Dot the specified a and b. More...
 
static double Distance (DVector2 a, DVector2 b)
 Distance the specified a and b. More...
 
static DVector2 Lerp (DVector2 a, DVector2 b, double t)
 Lerp the specified a, b and t. More...
 
static DVector2 operator* (DVector2 a, double b)
 Computes the product of a and b, yielding a new T:DVector2. More...
 
static DVector2 operator/ (DVector2 a, double b)
 Computes the division of a and b, yielding a new T:DVector2. More...
 
static DVector2 operator+ (DVector2 a, DVector2 b)
 Adds a DVector2 to a DVector2, yielding a new T:DVector2. More...
 
static DVector2 operator- (DVector2 a, DVector2 b)
 Subtracts a DVector2 from a DVector2, yielding a new T:DVector2. More...
 

Public Attributes

double x
 
double y
 

Properties

double magnitude [get]
 Gets the magnitude of the vector. More...
 
DVector2 normalized [get]
 Gets the normalized version of this vector. More...
 

Detailed Description

Definition at line 8 of file DVector2.cs.

Constructor & Destructor Documentation

◆ DVector2()

ARLocation.DVector2.DVector2 ( double  x = 0.0,
double  y = 0.0 
)

Initializes a new instance of the T:DVector2 struct.

Parameters
xThe x coordinate.
yThe y coordinate.

Definition at line 54 of file DVector2.cs.

Member Function Documentation

◆ Distance()

static double ARLocation.DVector2.Distance ( DVector2  a,
DVector2  b 
)
static

Distance the specified a and b.

Returns
The distance.
Parameters
aThe alpha component.
bThe blue component.

Definition at line 127 of file DVector2.cs.

◆ Dot()

static double ARLocation.DVector2.Dot ( DVector2  a,
DVector2  b 
)
static

Dot the specified a and b.

Returns
The dot.
Parameters
aThe alpha component.
bThe blue component.

Definition at line 116 of file DVector2.cs.

◆ Equals()

bool ARLocation.DVector2.Equals ( DVector2  v,
double  e = 0.00005 
)

Equals the specified v and e.

Returns
The equals.
Parameters
vV.
eE.

Definition at line 75 of file DVector2.cs.

◆ Lerp()

static DVector2 ARLocation.DVector2.Lerp ( DVector2  a,
DVector2  b,
double  t 
)
static

Lerp the specified a, b and t.

Returns
The lerp.
Parameters
aThe alpha component.
bThe blue component.
tT.

Definition at line 139 of file DVector2.cs.

◆ Normalize()

void ARLocation.DVector2.Normalize ( )

Normalize this instance.

Definition at line 83 of file DVector2.cs.

◆ operator*()

static DVector2 ARLocation.DVector2.operator* ( DVector2  a,
double  b 
)
static

Computes the product of a and b, yielding a new T:DVector2.

Parameters
aThe DVector2 to multiply.
bThe double to multiply.
Returns
The T:DVector2 that is the a * b.

Definition at line 151 of file DVector2.cs.

◆ operator+()

static DVector2 ARLocation.DVector2.operator+ ( DVector2  a,
DVector2  b 
)
static

Adds a DVector2 to a DVector2, yielding a new T:DVector2.

Parameters
aThe first DVector2 to add.
bThe second DVector2 to add.
Returns
The T:DVector2 that is the sum of the values of a and b.

Definition at line 179 of file DVector2.cs.

◆ operator-()

static DVector2 ARLocation.DVector2.operator- ( DVector2  a,
DVector2  b 
)
static

Subtracts a DVector2 from a DVector2, yielding a new T:DVector2.

Parameters
aThe DVector2 to subtract from (the minuend).
bThe DVector2 to subtract (the subtrahend).
Returns
The T:DVector2 that is the a minus b.

Definition at line 193 of file DVector2.cs.

◆ operator/()

static DVector2 ARLocation.DVector2.operator/ ( DVector2  a,
double  b 
)
static

Computes the division of a and b, yielding a new T:DVector2.

Parameters
aThe DVector2 to divide (the divident).
bThe double to divide (the divisor).
Returns
The T:DVector2 that is the a / b.

Definition at line 165 of file DVector2.cs.

◆ Set()

void ARLocation.DVector2.Set ( double  newX = 0.0,
double  newY = 0.0 
)

Set the specified x and y.

Parameters
newX
newY

Definition at line 95 of file DVector2.cs.

◆ ToString()

override string ARLocation.DVector2.ToString ( )

Returns a T:System.String that represents the current T:DVector2.

Returns
A T:System.String that represents the current T:DVector2.

Definition at line 105 of file DVector2.cs.

◆ toVector2()

Vector2 ARLocation.DVector2.toVector2 ( )

Converts to a Vector2.

Returns
The vector2.

Definition at line 64 of file DVector2.cs.

Property Documentation

◆ magnitude

double ARLocation.DVector2.magnitude
get

Gets the magnitude of the vector.

The magnitude.

Definition at line 17 of file DVector2.cs.

◆ normalized

DVector2 ARLocation.DVector2.normalized
get

Gets the normalized version of this vector.

The normalized.

Definition at line 29 of file DVector2.cs.


The documentation for this struct was generated from the following file: