/// <summary> /// Function to render the geometry /// </summary> /// <param name="map">The map object, mainly needed for transformation purposes.</param> /// <param name="geometry">The geometry to symbolize.</param> /// <param name="graphics">The graphics object to use.</param> public void Render(MapViewport map, IGeometry geometry, Graphics graphics) { switch (geometry.OgcGeometryType) { case OgcGeometryType.Point: case OgcGeometryType.MultiPoint: _pointSymbolizer.Render(map, (IPuntal)geometry, graphics); return; case OgcGeometryType.LineString: case OgcGeometryType.MultiLineString: _lineSymbolizer.Render(map, (ILineal)geometry, graphics); return; case OgcGeometryType.Polygon: case OgcGeometryType.MultiPolygon: _polygonSymbolizer.Render(map, (IPolygonal)geometry, graphics); return; case OgcGeometryType.GeometryCollection: foreach (var g in ((IGeometryCollection)geometry)) { Render(map, g, graphics); } return; } throw new Exception("Unknown geometry type"); }
public void Render(Map map, Geometry geometry, Graphics graphics) { switch (geometry.GeometryType) { case GeometryType2.Point: case GeometryType2.MultiPoint: _pointSymbolizer.Render(map, (IPuntal)geometry, graphics); return; case GeometryType2.LineString: case GeometryType2.MultiLineString: _lineSymbolizer.Render(map, (ILineal)geometry, graphics); return; case GeometryType2.Polygon: case GeometryType2.MultiPolygon: _polygonSymbolizer.Render(map, (IPolygonal)geometry, graphics); return; case GeometryType2.GeometryCollection: foreach (Geometry g in ((GeometryCollection)geometry).Collection) { Render(map, g, graphics); } return; } throw new Exception("Unknown geometry type"); }
public static void DrawPoint(IPointSymbolizer symbolizer, Graphics g, IPoint point, MapViewport map) { if (point == null) { return; } symbolizer.Render(map, point, g); }
public static RectangleF DrawPointEx(IPointSymbolizer symbolizer, Graphics g, IPoint point, MapViewport map) { if (point == null) { return(RectangleF.Empty); } symbolizer.Render(map, point, g); return(((IPointSymbolizerEx)symbolizer).CanvasArea); }
public static void DrawMultiPoint(IPointSymbolizer symbolizer, Graphics g, MultiPoint points, Map map) { symbolizer.Render(map, points, g); }
public static void DrawPoint(IPointSymbolizer symbolizer, Graphics g, Point point, Map map) { if (point == null) return; symbolizer.Render(map, point, g); }
public static void DrawMultiPoint(IPointSymbolizer symbolizer, Graphics g, IMultiPoint points, MapViewport map) { symbolizer.Render(map, points, g); }
public static RectangleF DrawMultiPointEx(IPointSymbolizer symbolizer, Graphics g, IMultiPoint points, MapViewport map) { symbolizer.Render(map, points, g); return(((IPointSymbolizerEx)symbolizer).CanvasArea); }
public void DrawMultiPoint(IPointSymbolizer symbolizer, IGraphics g, IMultiPoint points, Map map) { symbolizer.Render(map, points, g); }