MCPcopy Create free account
hub / github.com/axmolengine/axmol / distance

Method distance

core/math/Vec3.cpp:135–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133}
134
135float Vec3::distance(const Vec3& v) const
136{
137 float dx = v.x - x;
138 float dy = v.y - y;
139 float dz = v.z - z;
140
141 return std::sqrt(dx * dx + dy * dy + dz * dz);
142}
143
144float Vec3::distanceSquared(const Vec3& v) const
145{

Callers 6

setChunksLODMethod · 0.45
calculateSlopeMethod · 0.45
createMethod · 0.45
createSplineSegmentMethod · 0.45
updatePUAffectorMethod · 0.45

Calls 1

sqrtFunction · 0.50

Tested by

no test coverage detected