Esempio n. 1
0
 /// <summary>
 /// Applies the inverse of this transformation to the given transformation.
 /// </summary>
 /// <param name="other"></param>
 public Orient3d ApplyInverse(ref Orient3d other)
 {
     return(new Orient3d
     {
         Rotation = Rotation.ApplyInverse(ref other.Rotation),
         Translation = ApplyInverse(other.Translation)
     });
 }
Esempio n. 2
0
        /// <summary>
        /// Creates a relative transformation from t0 to t1.
        /// </summary>
        /// <param name="from"></param>
        /// <param name="to"></param>
        /// <returns></returns>
        public static Orient3d CreateFromTo(ref Orient3d from, ref Orient3d to)
        {
            var inv = from.Inverse;

            return(to.Apply(ref inv));
        }
Esempio n. 3
0
 /// <summary>
 /// Creates a relative transformation from t0 to t1.
 /// </summary>
 /// <param name="from"></param>
 /// <param name="to"></param>
 /// <returns></returns>
 public static Orient3d CreateFromTo(Orient3d from, Orient3d to)
 {
     return(CreateFromTo(ref from, ref to));
 }
Esempio n. 4
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="other"></param>
 /// <param name="epsilon"></param>
 /// <returns></returns>
 public bool ApproxEquals(ref Orient3d other, double epsilon = D.ZeroTolerance)
 {
     return
         (Translation.ApproxEquals(other.Translation, epsilon) &&
          Rotation.ApproxEquals(ref other.Rotation, epsilon));
 }
Esempio n. 5
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="other"></param>
 /// <param name="epsilon"></param>
 /// <returns></returns>
 public bool ApproxEquals(Orient3d other, double epsilon = D.ZeroTolerance)
 {
     return(ApproxEquals(ref other, epsilon));
 }
Esempio n. 6
0
 /// <summary>
 /// Applies the inverse of this transformation to the given transformation.
 /// </summary>
 /// <param name="other"></param>
 public Orient3d ApplyInverse(Orient3d other)
 {
     return(ApplyInverse(ref other));
 }
Esempio n. 7
0
 /// <summary>
 /// Applies this transformation to the given transformation.
 /// </summary>
 /// <param name="other"></param>
 public Orient3d Apply(Orient3d other)
 {
     return(Apply(ref other));
 }
Esempio n. 8
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="scale"></param>
 /// <param name="orientation"></param>
 public Transform3d(Vector3d scale, Orient3d orientation)
 {
     Scale       = scale;
     Rotation    = orientation.Rotation;
     Translation = orientation.Translation;
 }