Constructs the vector If a single value is passed the vector, the vector will be cleared with this value If a vector with a higher dimension is passed the vector will hold the first values up to its dimension If mixed types are passed they will be joined together ( allowed types: vector, static array, $( I vt ))
Construct a Vector from another Vector
Construct a Vector from a single value
Sets all values of the vector to value
Returns the euclidean length of the vector
FloatingPoint valueType, Returns true if all values are not nan and finite, otherwise false
Componentwise binary vector-skalar operation: addition, subtraction, multiplication, division
Componentwise binary operation with aonther vector: addition, subtraction, multiplication, division
Componentwise binary skalar-vector operation: addition, subtraction, multiplication, division
FloatingPoint valueType, Returns true if all values are not nan and finite, otherwise false
Implements swizzling.
Support swizzling assignment like in shader languages.
Comparisson Operator
Op= Operation with a scalar
Componentwise Op= Operation with another vector
TODO : This does not work Negate the vector
Returns a pointer to the coordinates
Returns the current vector formatted as char[] slice of the passed in buffer excluding terminating \0. The terminator is still part of the buffer to be able to use write(ln) as well as printf using buffer.ptr
the value type of each vector element
specifies the dimension of the vector, can be 1, 2, 3 or 4
alias Vector!(int, 3) vec3i; alias Vector!(float, 4) vec4; alias Vector!(real, 2) vec2r;
Base template for all vector-types.