imageproc::drawing

Function draw_line_segment_mut

Source
pub fn draw_line_segment_mut<C>(
    canvas: &mut C,
    start: (f32, f32),
    end: (f32, f32),
    color: C::Pixel,
)
where C: Canvas,
Expand description

Draws a line segment on an image in place.

Draws as much of the line segment between start and end as lies inside the image bounds.

Uses Bresenham’s line drawing algorithm.