fn from(quat: Quaternion<S>) -> Matrix4<S> {
        let x2 = quat.v.x + quat.v.x;
        let y2 = quat.v.y + quat.v.y;
        let z2 = quat.v.z + quat.v.z;

        let xx2 = x2 * quat.v.x;
        let xy2 = x2 * quat.v.y;
        let xz2 = x2 * quat.v.z;

        let yy2 = y2 * quat.v.y;
        let yz2 = y2 * quat.v.z;
        let zz2 = z2 * quat.v.z;

        let sy2 = y2 * quat.s;
        let sz2 = z2 * quat.s;
        let sx2 = x2 * quat.s;

        #[cfg_attr(rustfmt, rustfmt_skip)]
        Matrix4::new(
            S::one() - yy2 - zz2, xy2 + sz2, xz2 - sy2, S::zero(),
            xy2 - sz2, S::one() - xx2 - zz2, yz2 + sx2, S::zero(),
            xz2 + sy2, yz2 - sx2, S::one() - xx2 - yy2, S::zero(),
            S::zero(), S::zero(), S::zero(), S::one(),
        )
    }
Convert the quaternion to a 4 x 4 rotation matrix.
src/quaternion.rs