MCPcopy Create free account
hub / github.com/alignoth/alignoth / rC

Function rC

resources/vega.min.js:22598–22620  ·  view source on GitHub ↗
(t, e, n)

Source from the content-addressed store, hash-verified

22596 return { x: r + w + k * F, y: i + A + M * F, r: F };
22597 }
22598 function rC(t, e, n) {
22599 var r,
22600 i,
22601 o,
22602 a,
22603 s = t.x - e.x,
22604 u = t.y - e.y,
22605 l = s * s + u * u;
22606 l
22607 ? ((i = e.r + n.r),
22608 (i *= i),
22609 (a = t.r + n.r),
22610 i > (a *= a)
22611 ? ((r = (l + a - i) / (2 * l)),
22612 (o = Math.sqrt(Math.max(0, a / l - r * r))),
22613 (n.x = t.x - r * s - o * u),
22614 (n.y = t.y - r * u + o * s))
22615 : ((r = (l + i - a) / (2 * l)),
22616 (o = Math.sqrt(Math.max(0, i / l - r * r))),
22617 (n.x = e.x + r * s - o * u),
22618 (n.y = e.y + r * u + o * s)))
22619 : ((n.x = e.x + n.r), (n.y = e.y));
22620 }
22621 function iC(t, e) {
22622 var n = t.r + e.r - 1e-6,
22623 r = e.x - t.x,

Callers 1

sCFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected