circleintersection.d.ts 1.3 KB

1234567891011121314151617181920212223242526272829
  1. /** Returns the intersection area of a bunch of circles (where each circle
  2. is an object having an x,y and radius property) */
  3. export declare function intersectionArea(circles: any, stats?: any): number;
  4. /** returns whether a point is contained by all of a list of circles */
  5. export declare function containedInCircles(point: any, circles: any): boolean;
  6. /** Circular segment area calculation. See http://mathworld.wolfram.com/CircularSegment.html */
  7. export declare function circleArea(r: any, width: any): number;
  8. /** euclidean distance between two points */
  9. export declare function distance(p1: any, p2: any): number;
  10. /** Returns the overlap area of two circles of radius r1 and r2 - that
  11. have their centers separated by distance d. Simpler faster
  12. circle intersection for only two circles */
  13. export declare function circleOverlap(r1: any, r2: any, d: any): number;
  14. /** Given two circles (containing a x/y/radius attributes),
  15. returns the intersecting points if possible.
  16. note: doesn't handle cases where there are infinitely many
  17. intersection points (circles are equivalent):, or only one intersection point*/
  18. export declare function circleCircleIntersection(p1: any, p2: any): ({
  19. x: any;
  20. y: number;
  21. } | {
  22. x: number;
  23. y: any;
  24. })[];
  25. /** Returns the center of a bunch of points */
  26. export declare function getCenter(points: any): {
  27. x: number;
  28. y: number;
  29. };