Vector2T

A 2 dimensional vector.

Constructors

this
this(T x)

Constructor

this
this(T x, T y)

Constructor

this
this(Vector3T!T vec)
Undocumented in source.
this
this(Vector4T!T vec)
Undocumented in source.

Members

Aliases

Type
alias Type = T
Undocumented in source.
toString
alias toString = ToString

Backwards compatiblity with glmath.

Functions

Difference
GVector Difference(T2 other)
Distance
T Distance(T2 other)
Dot
T Dot(GVector other)

Dot product of a vector.

Length
T Length()
Normalize
GVector Normalize()
ToString
string ToString()
opBinary
GVector opBinary(T2 other)
Undocumented in source. Be warned that the author may not have intended to support it.
opBinary
GVector opBinary(T2 other)
Undocumented in source. Be warned that the author may not have intended to support it.
opOpAssign
void opOpAssign(T2 other)
Undocumented in source. Be warned that the author may not have intended to support it.
ptr
T* ptr()

Pointer to the underlying array data.

Manifest constants

Dimensions
enum Dimensions;
Undocumented in source.

Static functions

Down
GVector Down()
Left
GVector Left()
One
GVector One()
Right
GVector Right()
Up
GVector Up()
Zero
GVector Zero()

Variables

X
T X;

The X component

Y
T Y;

The Y component

Meta