Skip to main content

Intersection

line-line

line-line() 

Checks for a line-line intersection between the given points and returns its position, otherwise none.

Point 1

Point 2

Point 3

Point 4

ray:

If true, handle both lines as infinite rays

Epsilon

line-cubic

line-cubic() 

Finds the intersections of a line and cubic bezier.

Bezier start point

Bezier end point

Bezier control point 1

Bezier control point 2

Line start point

Line end point

ray:

When true, intersections will be found for the whole line instead of inbetween the given points.

line-path

line-path() 

Finds the intersections of a line and path in 2D. The path should be given as a drawable of type path.

Line start

Line end

The path.

path-path

path-path() 

Finds the intersections between two path drawables in 2D.

Path a

Path b

samples:

Number of samples to use for bezier curves