Planar64Affine3::from_translation
This commit is contained in:
parent
4859c37780
commit
af3abbcb4d
@ -659,6 +659,13 @@ impl Planar64Affine3{
|
|||||||
Self{matrix3,translation}
|
Self{matrix3,translation}
|
||||||
}
|
}
|
||||||
#[inline]
|
#[inline]
|
||||||
|
pub const fn from_translation(translation:Planar64Vec3)->Self{
|
||||||
|
Self{
|
||||||
|
matrix3:mat3::identity(),
|
||||||
|
translation,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#[inline]
|
||||||
pub fn transform_point3(&self,point:Planar64Vec3)->vec3::Vector3<Fixed<2,64>>{
|
pub fn transform_point3(&self,point:Planar64Vec3)->vec3::Vector3<Fixed<2,64>>{
|
||||||
self.translation.fix_2()+self.matrix3*point
|
self.translation.fix_2()+self.matrix3*point
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user