MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / distanceSquared

Method distanceSquared

Source/Support/Geometry.cpp:106–110  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

104}
105
106float Vec2::distanceSquared(const Vec2& vec) const {
107 float dx = x - vec.x;
108 float dy = y - vec.y;
109 return dx * dx + dy * dy;
110}
111
112float Vec2::length() const {
113 return bx::sqrt(x * x + y * y);

Callers 2

runDecisionTreeMethod · 0.80
vec2_distance_squaredFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected