예제 #1
0
        /// <summary>
        /// Returns the inverse of the transform, under the assumption that
        /// the transformation is composed of rotation and translation
        /// (no scaling, use <see cref="AffineInverse"/> for transforms with scaling).
        /// </summary>
        /// <returns>The inverse matrix.</returns>
        public Transform3D Inverse()
        {
            Basis basisTr = basis.Transposed();

            return(new Transform3D(basisTr, basisTr.Xform(-origin)));
        }
예제 #2
0
        /// <summary>
        /// Returns the inverse of the transform, under the assumption that
        /// the transformation is composed of rotation, scaling, and translation.
        /// </summary>
        /// <seealso cref="Inverse"/>
        /// <returns>The inverse transformation matrix.</returns>
        public Transform3D AffineInverse()
        {
            Basis basisInv = basis.Inverse();

            return(new Transform3D(basisInv, basisInv.Xform(-origin)));
        }