Skip to main content

hit_edge

Function hit_edge 

Source
pub fn hit_edge(
    overlays: &[Overlay],
    m: &Mapping,
    pos: Pos2,
) -> Option<(usize, u32, [f64; 2])>
Expand description

The outline under pos (points), topmost overlay first, guides left out: the overlay’s index, the segment (between points i and i + 1 of a path or a line, the box’s top, right, bottom and left edges 0 to 3, 0 for a circle or an ellipse) and the nearest point of it in image pixels.