Remove transforma_as_point method
This commit is contained in:
parent
e873d4621b
commit
8518ce78e8
1 changed files with 1 additions and 7 deletions
|
@ -40,12 +40,6 @@ pub trait Transform<P: EuclideanSpace>: Sized {
|
||||||
/// Transform a point using this transform.
|
/// Transform a point using this transform.
|
||||||
fn transform_point(&self, point: P) -> P;
|
fn transform_point(&self, point: P) -> P;
|
||||||
|
|
||||||
/// Transform a vector as a point using this transform.
|
|
||||||
#[inline]
|
|
||||||
fn transform_as_point(&self, vec: P::Diff) -> P::Diff {
|
|
||||||
self.transform_point(P::from_vec(vec)).to_vec()
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Combine this transform with another, yielding a new transformation
|
/// Combine this transform with another, yielding a new transformation
|
||||||
/// which has the effects of both.
|
/// which has the effects of both.
|
||||||
fn concat(&self, other: &Self) -> Self;
|
fn concat(&self, other: &Self) -> Self;
|
||||||
|
@ -109,7 +103,7 @@ impl<P: EuclideanSpace, R: Rotation<P>> Transform<P> for Decomposed<P::Diff, R>
|
||||||
Decomposed {
|
Decomposed {
|
||||||
scale: self.scale * other.scale,
|
scale: self.scale * other.scale,
|
||||||
rot: self.rot.concat(&other.rot),
|
rot: self.rot.concat(&other.rot),
|
||||||
disp: self.transform_as_point(other.disp.clone()),
|
disp: self.disp + other.disp,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue