Example #1
0
        /// <summary>
        /// Gets the ray value.
        /// </summary>
        public Point3D GetRayValue(Point3D ptNear, Point3D ptFar, double zValue)
        {
            LinearTransform t = new LinearTransform();

            t.Init(ptNear.Z, ptFar.Z, 0, 1);
            double f = t.Transform(zValue);

            t.Init(0, 1, ptNear.X, ptFar.X);
            double x = t.Transform(f);

            t.Init(0, 1, ptNear.Y, ptFar.Y);
            double y = t.Transform(f);

            return(new Point3D(x, y, zValue));
        }
Example #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Vector3DTransform"/> class.
 /// </summary>
 public Vector3DTransform()
 {
     TX = new LinearTransform();
     TY = new LinearTransform();
     TZ = new LinearTransform();
 }
Example #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Point3DTransform"/> class.
 /// </summary>
 public Point3DTransform()
 {
     TX = new LinearTransform();
     TY = new LinearTransform();
     TZ = new LinearTransform();
 }
Example #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Point3DTransform"/> class.
 /// </summary>
 public Point3DTransform()
 {
     TX = new LinearTransform();
     TY = new LinearTransform();
     TZ = new LinearTransform();
 }
Example #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Vector3DTransform"/> class.
 /// </summary>
 public Vector3DTransform()
 {
     TX = new LinearTransform();
     TY = new LinearTransform();
     TZ = new LinearTransform();
 }
Example #6
0
        /// <summary>
        /// Gets the ray value.
        /// </summary>
        public Point3D GetRayValue(Point3D ptNear, Point3D ptFar, double zValue)
        {
            LinearTransform t = new LinearTransform();
            t.Init(ptNear.Z, ptFar.Z, 0, 1);
            double f = t.Transform(zValue);

            t.Init(0, 1, ptNear.X, ptFar.X);
            double x = t.Transform(f);

            t.Init(0, 1, ptNear.Y, ptFar.Y);
            double y = t.Transform(f);

            return new Point3D(x, y, zValue);
        }