- distanceTo
T distanceTo(Vector other)
- fastInverseLength
T fastInverseLength()
Faster but less accurate inverse of Euclidean length.
- fastNormalize
void fastNormalize()
Faster but less accurate in-place normalization.
- fastNormalized
Vector fastNormalized()
Faster but less accurate vector normalization.
- getOrthogonalVector
Vector getOrthogonalVector()
Gets an orthogonal vector from a 3-dimensional vector.
Doesn’t normalize the output.
- inverseLength
T inverseLength()
- length
T length()
- normalize
void normalize()
- normalized
Vector normalized()
- opAssign
Vector opAssign(U x)
Assign a Vector from a compatible type.
- opAssign
Vector opAssign(U arr)
Assign a Vector with a static array type.
- opAssign
Vector opAssign(U arr)
Assign with a dynamic array.
Size is checked in debug-mode.
- opAssign
Vector opAssign(U u)
Assign from a samey Vector.
- opAssign
Vector opAssign(U x)
Assign from other vectors types (same size, compatible type).
- opBinary
Vector opBinary(U operand)
Undocumented in source. Be warned that the author may not have intended to support it.
- opBinaryRight
Vector opBinaryRight(U operand)
Undocumented in source. Be warned that the author may not have intended to support it.
- opCast
U opCast()
Casting to small vectors of the same size.
- opDollar
int opDollar()
Implement slices operator overloading.
Allows to go back to slice world.
- opEquals
bool opEquals(U other)
Undocumented in source. Be warned that the author may not have intended to support it.
- opEquals
bool opEquals(U other)
Undocumented in source. Be warned that the author may not have intended to support it.
- opIndex
T opIndex(size_t i)
Undocumented in source. Be warned that the author may not have intended to support it.
- opIndex
const(T) opIndex(size_t i)
Undocumented in source. Be warned that the author may not have intended to support it.
- opIndexAssign
T opIndexAssign(U x, size_t i)
Undocumented in source. Be warned that the author may not have intended to support it.
- opOpAssign
Vector opOpAssign(U operand)
Undocumented in source. Be warned that the author may not have intended to support it.
- opOpAssign
Vector opOpAssign(U operand)
Undocumented in source. Be warned that the author may not have intended to support it.
- opSlice
T[] opSlice()
- opSlice
T[] opSlice(int a, int b)
Undocumented in source. Be warned that the author may not have intended to support it.
- opUnary
Vector opUnary()
Undocumented in source. Be warned that the author may not have intended to support it.
- ptr
inout(T)* ptr()
- squaredDistanceTo
T squaredDistanceTo(Vector v)
Undocumented in source. Be warned that the author may not have intended to support it.
- squaredLength
T squaredLength()
- toString
string toString()
Converts to a pretty string.
Generic 1D small vector.