Exemple #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)
     });
 }
Exemple #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));
        }
Exemple #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));
 }
Exemple #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));
 }
Exemple #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));
 }
Exemple #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));
 }
Exemple #7
0
 /// <summary>
 /// Applies this transformation to the given transformation.
 /// </summary>
 /// <param name="other"></param>
 public Orient3d Apply(Orient3d other)
 {
     return(Apply(ref other));
 }
Exemple #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;
 }