Aspose.GIS for .NET is a library designed to enable developers to work with geospatial data in their .NET applications. It's part of the Aspose suite of APIs, which are known for providing powerful, file-format-specific libraries for various development needs.
using (var map = new Map(800, 400))
{
map.Add(VectorLayer.Open(dataDir + "land.shp", Drivers.Shapefile));
map.Render(dataDir + "land_out.svg", Renderers.Svg);
}
using (var map = new Map(500, 450))
{
var symbolizer = new SimpleFill { FillColor = Color.Azure, StrokeColor = Color.Brown };
map.Add(VectorLayer.Open(dataDir + "polygons.geojson", Drivers.GeoJson), symbolizer);
map.Render(dataDir + "polygons_out.svg", Renderers.Svg);
}
using (var map = new Map(1000, 634))
{
var symbolizer = new SimpleLine { Width = 1.5, Color = Color.FromArgb(0xAE, 0xD9, 0xFD) };
var labeling = new SimpleLabeling(labelAttribute: "name")
{
HaloSize = 1,
Placement = new LineLabelPlacement
{
Alignment = LineLabelAlignment.Parallel,
}
};
map.Add(VectorLayer.Open(dataDir + "lines.geojson", Drivers.GeoJson), symbolizer, labeling);
map.Padding = 50;
map.Render(dataDir + "lines_labeling_parallel_out.svg", Renderers.Svg);
}
using (var map = new Map(500, 200))
{
var symbol = new SimpleMarker() { Size = 7, StrokeWidth = 1, FillColor = Color.Red };
map.Add(VectorLayer.Open(dataDir + "points.geojson", Drivers.GeoJson), symbol);
map.Padding = 20;
map.Render(dataDir + "points_out.svg", Renderers.Svg);
}
There are a simple way to install Aspose.GIS for .NET onto your system:
Our API is supported on most platforms and operating systems. Before running the code, please make sure your system meets the appropriate requirements.
Try the features of our library to see new opportunities. Live demos in C#
You can also look at the various features of our GIS library.