calculate the length of a vector
float length(float x)
float length(vec2 x)
float length(vec3 x)
float length(vec4 x)
x
: Specifies a vector of which to calculate the length.length
returns the length of the vector. i.e.,
$$
\sqrt{x[0]^2 + x[1]^2 + \dots}
$$