MCPcopy Create free account
hub / github.com/NikLever/ThreeJS-PathEditor / calcDistanceBetweenTwoPoints

Method calcDistanceBetweenTwoPoints

geometry.js:67–71  ·  view source on GitHub ↗
( a, b )

Source from the content-addressed store, hash-verified

65 }
66
67 static calcDistanceBetweenTwoPoints( a, b ){
68 const dx = a.x - b.x;
69 const dy = a.y - b.y;
70 return Math.sqrt( dx*dx + dy*dy );
71 }
72
73 static calcPointOnCircle( cx, cy, radius, theta ){
74 const x = Math.cos( theta ) * radius + cx;

Callers 1

addNodeMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected