[][src]Trait geo_clipper::Clipper

pub trait Clipper<T: ?Sized> {
    fn difference(&self, other: &T, factor: f64) -> MultiPolygon<f64>;
fn intersection(&self, other: &T, factor: f64) -> MultiPolygon<f64>;
fn union(&self, other: &T, factor: f64) -> MultiPolygon<f64>;
fn xor(&self, other: &T, factor: f64) -> MultiPolygon<f64>; }

This trait defines the boolean operations between polygons.

The factor parameter in its methods is used to scale shapes before and after applying the boolean operation to avoid precision loss since Clipper (the underlaying library) performs integer computation.

Required methods

fn difference(&self, other: &T, factor: f64) -> MultiPolygon<f64>

fn intersection(&self, other: &T, factor: f64) -> MultiPolygon<f64>

fn union(&self, other: &T, factor: f64) -> MultiPolygon<f64>

fn xor(&self, other: &T, factor: f64) -> MultiPolygon<f64>

Loading content...

Implementors

impl<T: ToOwnedPolygon + ?Sized, U: ToOwnedPolygon + ?Sized> Clipper<T> for U[src]

Loading content...