Intersections returns a list of points of all intersections of path p with q. The intersection can be tangent (touch) or secant (cross). If the two paths are partially coincident it will return an intersection at the start and end. Equal paths have no intersections. If q is nil it returns the inters
(q *Path)
| 233 | // intersections. If q is nil it returns the intersections of p with itself. Intersections are sorted from left-to-right, and |
| 234 | // otherwise from bottom-to-top. |
| 235 | func (p *Path) Intersections(q *Path) []Point { |
| 236 | _, zs := relate(p.Split(), q.Split(), true) |
| 237 | return zs |
| 238 | } |
| 239 | |
| 240 | // Touches returns true if path p and q are not disjoint, their boundaries/interiors intersect. |
| 241 | // This is different from DE-9IM's definition of Touches. |