Transform2D is a class used to perform Affine transforms on a matrix. Affine transforms are those which can be mathematically reversed. Examples include translation, scaling, shearing, and the like.
 public virtual void SetWorldTransform(Transform2D aTransform)
 {
     bool result = GDI32.SetWorldTransform(this, ref aTransform.fMatrix);
 }
        private Transform2D GetWorldTransform()
        {
            XFORM aTransform = new XFORM();
            bool result = GDI32.GetWorldTransform(this, out aTransform);

            Transform2D trans = new Transform2D();
            trans.SetTransform(aTransform);

            return trans;
        }
Пример #3
0
        // Find a transform which maps p0, q0, and r0 to p1, p1 and r1 respectively
        public bool MapTri(float px0, float py0, float qx0, float qy0, float rx0, float ry0,
                             float px1, float py1, float qx1, float qy1, float rx1, float ry1)
        {
            if (!MapTri(px0, py0, qx0, qy0, rx0, ry0))
                return false;

            Invert();		// transform p0, q0, and r0 back to (0,0),(1,0),(0,1)

            Transform2D map1 = new Transform2D();

            if (!map1.MapTri(px1, py1, qx1, qy1, rx1, ry1))
                return false;

            return Combine(map1.fMatrix);	// then to p1,r1,q1
        }
Пример #4
0
 public virtual void SetWorldTransform(Transform2D aTransform)
 {
     DeviceContext.SetWorldTransform(aTransform);
 }
Пример #5
0
 public virtual void SetWorldTransform(Transform2D aTransform)
 {
 }