Esempio n. 1
0
        public void TransformTest()
        {
            var tx = CoordinateTransformer.CreatePixelTransformer(400, 200, 0, 0, 2);

            TestPointTransform(tx, 200.0, 100.0, 0.0, 0.0);
            TestPointTransform(tx, 0.0, 0.0, -1.0, 0.5);
            TestPointTransform(tx, 400.0, 200.0, 1.0, -0.5);
        }
Esempio n. 2
0
        private Func <Tuple <int, int>, Tuple <double, double> > MakeConverter(FractalImageSettings input)
        {
            var tx = CoordinateTransformer.CreatePixelTransformer(input.PixelWidth, input.PixelHeight, input.OriginX, input.OriginY, input.LogicalWidth);

            return((pixPos) => tx.TransformToLocal(pixPos.Item1, pixPos.Item2));
        }