Exemple #1
0
 public static void Rotate(IGeometry geometry, double degrees, Point center)
 {
     foreach (var vertex in geometry.AllVertices())
     {
         Rotate(vertex, degrees, center);
     }
 }
Exemple #2
0
 public static void Scale(IGeometry geometry, double scale, Point center)
 {
     foreach (var vertex in geometry.AllVertices())
     {
         Scale(vertex, scale, center);
     }
 }
 public static void Transform(IGeometry geometry, ICoordinateTransformation coordinateTransformation)
 {
     var vertices = geometry.AllVertices();
     foreach (var vertex in vertices)
     {
         double[] point = coordinateTransformation.MathTransform.Transform(new[] { vertex.X, vertex.Y });
         vertex.X = point[0];
         vertex.Y = point[1];
     }
 }
Exemple #4
0
        public static void Transform(IGeometry geometry, ICoordinateTransformation coordinateTransformation)
        {
            var vertices = geometry.AllVertices();

            foreach (var vertex in vertices)
            {
                double[] point = coordinateTransformation.MathTransform.Transform(new[] { vertex.X, vertex.Y });
                vertex.X = point[0];
                vertex.Y = point[1];
            }
        }
Exemple #5
0
 public IGeometry Transform(string fromCRS, string toCRS, IGeometry geometry)
 {
     Transform(geometry.AllVertices(), _toLatLon[fromCRS]);
     Transform(geometry.AllVertices(), _fromLatLon[toCRS]);
     return(geometry); // this method should not have a return value
 }
 public IGeometry Transform(string fromCRS, string toCRS, IGeometry geometry)
 {
     Transform(geometry.AllVertices(), _toLatLon[fromCRS]);
     Transform(geometry.AllVertices(), _fromLatLon[toCRS]);
     return geometry; // this method should not have a return value
 }