Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/xfischer/nettopologysuite.diagnostics

Spatial trace and debugger visualizers for NTS
https://github.com/xfischer/nettopologysuite.diagnostics

debugger-visualizers diagnostics nettopologysuite nts spatial

Last synced: 9 days ago
JSON representation

Spatial trace and debugger visualizers for NTS

Awesome Lists containing this project

README

        

# NetTopologySuite.Diagnostics

Spatial tracing and debugger visualizers for NetTopology geometries.

.Net Standard replacement of [SqlServerSpatial.Toolkit](https://github.com/xfischer/SqlServerSpatial.Toolkit)

- Only enables tracing for the moment. A viewer will soon be ported.

```
using NetTopologySuite.Diagnostics.Tracing;

// Enable tracing
SpatialTrace.Enable();
// Trace sample geometry instance.
// Works with any IGeometry instance, and IEnumerable
SpatialTrace.TraceGeometry(geometry, "Sample geometry with default style");

// Change styling
SpatialTrace.SetLineWidth(3); // Current stroke style is 3px wide
SpatialTrace.SetFillColor(Color.FromArgb(128, 255, 0, 0)); // Fills with red

// Style is applied to subsequent traces
SpatialTrace.TraceGeometry(geometry, "Some text");

// Reset style
SpatialTrace.ResetStyle();
```