GetVectorLength Function

Calculates a vector's length.

float GetVectorLength(const float vec[3], bool squared)

Parameters

const float[3] vec

Vector.

bool squared

If true, the result will be squared (for optimization).

Return Value

Vector length (magnitude).