makepad_vector/geometry/transformation.rs
1use crate::geometry::{Point, Vector};
2
3/// A trait for transformations in 2-dimensional Euclidian space.
4pub trait Transformation {
5 /// Applies `self` to the given `point`.
6 fn transform_point(&self, point: Point) -> Point;
7
8 /// Applies `self` to the given `vector`.
9 fn transform_vector(&self, vector: Vector) -> Vector;
10}