MCPcopy Create free account
hub / github.com/WheretIB/nullc / length2

Function length2

NULLC/includes/math.cpp:144–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

142 }
143
144 float length2(float4* v)
145 {
146 return sqrt(v->x * v->x + v->y * v->y);
147 }
148 float normalize2(float4* v)
149 {
150 float len = length2(v), invLen = 1.0f / len;

Callers 1

normalize2Function · 0.85

Calls 1

sqrtFunction · 0.85

Tested by

no test coverage detected