diff --git a/nalgebra-glm/src/gtx/quaternion.rs b/nalgebra-glm/src/gtx/quaternion.rs index f912c409..d4f82af2 100644 --- a/nalgebra-glm/src/gtx/quaternion.rs +++ b/nalgebra-glm/src/gtx/quaternion.rs @@ -93,6 +93,6 @@ pub fn mat3_to_quat(x: &TMat3) -> Qua { /// Converts a rotation matrix in homogeneous coordinates to a quaternion. pub fn to_quat(x: &TMat4) -> Qua { - let rot = x.fixed_slice::<3, 3>(0, 0).into_owned(); + let rot = x.fixed_view::<3, 3>(0, 0).into_owned(); mat3_to_quat(&rot) } diff --git a/nalgebra-glm/src/gtx/transform2.rs b/nalgebra-glm/src/gtx/transform2.rs index f389e4b1..56f736d7 100644 --- a/nalgebra-glm/src/gtx/transform2.rs +++ b/nalgebra-glm/src/gtx/transform2.rs @@ -7,7 +7,7 @@ pub fn proj2d(m: &TMat3, normal: &TVec2) -> TMat3 { let mut res = TMat3::identity(); { - let mut part = res.fixed_slice_mut::<2, 2>(0, 0); + let mut part = res.fixed_view_mut::<2, 2>(0, 0); part -= normal * normal.transpose(); } @@ -19,7 +19,7 @@ pub fn proj(m: &TMat4, normal: &TVec3) -> TMat4 { let mut res = TMat4::identity(); { - let mut part = res.fixed_slice_mut::<3, 3>(0, 0); + let mut part = res.fixed_view_mut::<3, 3>(0, 0); part -= normal * normal.transpose(); } @@ -31,7 +31,7 @@ pub fn reflect2d(m: &TMat3, normal: &TVec2) -> TMat3 { let mut res = TMat3::identity(); { - let mut part = res.fixed_slice_mut::<2, 2>(0, 0); + let mut part = res.fixed_view_mut::<2, 2>(0, 0); part -= (normal * T::from_subset(&2.0)) * normal.transpose(); } @@ -43,7 +43,7 @@ pub fn reflect(m: &TMat4, normal: &TVec3) -> TMat4 { let mut res = TMat4::identity(); { - let mut part = res.fixed_slice_mut::<3, 3>(0, 0); + let mut part = res.fixed_view_mut::<3, 3>(0, 0); part -= (normal * T::from_subset(&2.0)) * normal.transpose(); }