private double LonFromX(int x) { Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); Coordinate c = p.PointToCoord(new Point(x, 0)); return(c.Longitude); //return bounds.XMin + bounds.Width * ((double)x / this.Width); }
private double LatFromY(int y) { //Projection p = new Projection(bounds.Height, this.Height); Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); Coordinate c = p.PointToCoord(new Point(0, y)); return(c.Latitude); //return bounds.YMin + bounds.Height * ((double)y / this.Height); }
private Coordinate PointToCoord(int x, int y) { Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); return(p.PointToCoord(new Point(x, y))); }
private Coordinate PointToCoord(int x, int y) { Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); return p.PointToCoord(new Point(x, y)); }
private double LonFromX(int x) { Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); Coordinate c = p.PointToCoord(new Point(x, 0)); return c.Longitude; //return bounds.XMin + bounds.Width * ((double)x / this.Width); }
private double LatFromY(int y) { //Projection p = new Projection(bounds.Height, this.Height); Projection p = new Projection(bounds.Width, this.Width, new Coordinate(bounds.XMin, bounds.YMax)); Coordinate c = p.PointToCoord(new Point(0, y)); return c.Latitude; //return bounds.YMin + bounds.Height * ((double)y / this.Height); }