Trait libreda_pnr::db::MapPointwise[]

pub trait MapPointwise<T> where
    T: CoordinateType
{ pub fn transform<F>(&self, transformation: F) -> Self
    where
        F: Fn(Point<T>) -> Point<T>
; }

Transform the geometrical object by transforming each point of it.

Required methods

pub fn transform<F>(&self, transformation: F) -> Self where
    F: Fn(Point<T>) -> Point<T>, 

Point wise transformation.

Loading content...

Implementors

impl<T> MapPointwise<T> for Edge<T> where
    T: CoordinateType

impl<T> MapPointwise<T> for MultiPolygon<T> where
    T: CoordinateType

impl<T> MapPointwise<T> for Point<T> where
    T: CoordinateType

Point wise transformation for a single point.

pub fn transform<F>(&self, transformation: F) -> Point<T> where
    F: Fn(Point<T>) -> Point<T>, 

Point wise transformation.

impl<T> MapPointwise<T> for PointString<T> where
    T: CoordinateType

impl<T> MapPointwise<T> for Polygon<T> where
    T: CoordinateType

impl<T> MapPointwise<T> for Rect<T> where
    T: CoordinateType

Point wise transformation of the two corner points.

pub fn transform<F>(&self, transformation: F) -> Rect<T> where
    F: Fn(Point<T>) -> Point<T>, 

Point wise transformation.

impl<T> MapPointwise<T> for SimplePolygon<T> where
    T: CoordinateType

impl<T> MapPointwise<T> for Vector<T> where
    T: CoordinateType

impl<T, S> MapPointwise<T> for Text<T, S> where
    S: Clone,
    T: CoordinateType

Point wise transformation for a single point.

pub fn transform<F>(&self, transformation: F) -> Text<T, S> where
    F: Fn(Point<T>) -> Point<T>, 

Point wise transformation.

Loading content...