mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Add ellipse changes no angle
Signed-off-by: Mark Tolmacs <mark@lazycat.hu>
This commit is contained in:
parent
d9ea7190ec
commit
7b4e989d65
12 changed files with 97 additions and 357 deletions
|
@ -1,5 +1,5 @@
|
|||
import { radians } from "./angle";
|
||||
import { arc, arcIncludesPoint, arcSegmentInterceptPoint } from "./arc";
|
||||
import { arc, arcIncludesPoint, arcSegmentInterceptPoints } from "./arc";
|
||||
import { point } from "./point";
|
||||
import { segment } from "./segment";
|
||||
|
||||
|
@ -33,7 +33,7 @@ describe("point on arc", () => {
|
|||
describe("intersection", () => {
|
||||
it("should report correct interception point", () => {
|
||||
expect(
|
||||
arcSegmentInterceptPoint(
|
||||
arcSegmentInterceptPoints(
|
||||
arc(point(0, 0), 1, radians(-Math.PI / 4), radians(Math.PI / 4)),
|
||||
segment(point(2, 1), point(0, 0)),
|
||||
),
|
||||
|
@ -42,7 +42,7 @@ describe("intersection", () => {
|
|||
|
||||
it("should report both interception points when present", () => {
|
||||
expect(
|
||||
arcSegmentInterceptPoint(
|
||||
arcSegmentInterceptPoints(
|
||||
arc(point(0, 0), 1, radians(-Math.PI / 4), radians(Math.PI / 4)),
|
||||
segment(point(0.9, -2), point(0.9, 2)),
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue