diff options
| author | Arne Dußin | 2020-12-20 03:58:46 +0100 |
|---|---|---|
| committer | Arne Dußin | 2020-12-20 16:41:52 +0100 |
| commit | 48f321a80970ebeb8374072b1d2e0a4d297aa348 (patch) | |
| tree | 8f6dbffef7ed507ae118919917fd69a7a9528c39 /src/transformable.rs | |
| parent | c073618d9773216ab4a2dcd7944589f38b1df751 (diff) | |
| download | graf_karto-48f321a80970ebeb8374072b1d2e0a4d297aa348.tar.gz graf_karto-48f321a80970ebeb8374072b1d2e0a4d297aa348.zip | |
Add dimensional indicator with scaling
Diffstat (limited to 'src/transformable.rs')
| -rw-r--r-- | src/transformable.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/transformable.rs b/src/transformable.rs new file mode 100644 index 0000000..c181bd6 --- /dev/null +++ b/src/transformable.rs @@ -0,0 +1,8 @@ +use nalgebra::Matrix3; + +/// Trait for things that can be stretched and rotated etc. as one pleases without +/// becoming invalid. A room for instance would fall into this category, while an icon might not. +pub trait NonRigidTransformable { + /// Applies the provided matrix to all vertices of this transformable element. + fn apply_matrix(&mut self, matrix: &Matrix3<f64>); +} |
