Vector

Describes a dot, or a direction in 3D space

Constructors

this
this()

Default constructor

this
this(double _x, double _y, double _z)

Construct by coordinates

this
this(Vector v)

Construnct copy

Members

Functions

opBinary
Vector opBinary(Vector u)

Vector x Vector multiplication

opBinary
Vector opBinary(real c)

Vector-Scalar multiplication

opBinary
Vector opBinary(Vector v)

Vector summ

opBinary
Vector opBinary(Vector v)

Vector difference

opBinary
double opBinary(Vector v)

Vector*Vector multiplication (returns Scalar)

opBinaryRight
Vector opBinaryRight(real c)

Scalar-Vector multiplication

rotate
Vector rotate(Quaternion q)

Rotate Vector, given the rotation quaternion

rotate
Vector rotate(double angle, Vector axis)

Rotate Vector, given angle and axis-Vector

rotate
Vector rotate(double angle, double x, double y, double z)

Rotate Vector, given angle and axis' coordinates

Properties

length
double length [@property getter]

Length of the vector

x
double x [@property getter]

Get x

x
double x [@property setter]

Set x

y
double y [@property getter]

Get y

y
double y [@property setter]

Set y

z
double z [@property getter]

Get z

z
double z [@property setter]

Set z

Meta