vec_mul(VECTOR* v1, VECTOR* v2)

Multiplies each coordinate of the first vector by the same coordinate of the second vector.

Parameters:

v1 - vector to be multiplied.
v2 - multiplication factors.

Returns:

v1

Modifies:

v1

Speed:

Fast

Algorithm:

v1.x = v1.x * v2.x;
v1.y = v1.y * v2.y;
v1.z = v1.z * v2.z;

Example:

vec_set(my.min_x,vector(-10,-10,-10));
vec_mul(my.min_x,my.scale_x);

See also:

Vectors, vec_scale, vec_dot, vec_cross

► latest version online