From 48f321a80970ebeb8374072b1d2e0a4d297aa348 Mon Sep 17 00:00:00 2001 From: Arne Dußin Date: Sun, 20 Dec 2020 03:58:46 +0100 Subject: Add dimensional indicator with scaling --- src/transformable.rs | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 src/transformable.rs (limited to 'src/transformable.rs') 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); +} -- cgit v1.2.3-70-g09d2