★ New in this release · feat/gpkg-3d-editor

3D / Z-Enabled GPKG Editor

A real, end-to-end 3D (Z + M) editing pipeline over GeoPackage — built for editing substation, pole, and conductor features right on the workstation, backed by an ESRI-compatible FeatureServer, and surfaced through the native ArcGIS Editor widget. No stubs, no flat geometry, no elevation lost — and no network required.

POINT ZPOLYGON ZLINESTRING ZM hasZ · hasMreturnZabsolute-heightOGC 12-128r12
What it does

Edit grid assets that actually have height

A pole top is not a pole base, and a conductor is not a line on the ground. Most "3D" GIS editors quietly flatten your data. This one doesn't.

  • Stores geometry as standard GPKG blobs — GEOMETRY(Z), POINT Z, POLYGON Z — for poles, structures, and conductor spans.
  • Round-trips the Z (and M) ordinate exactly: an ESRI 3D point {x,y,z:1500.5} comes back as z = 1500.5.
  • Each vertex renders at its stored elevation above the ellipsoid, matching the world-elevation ground — attachment heights and clearances stay honest.
  • Schema-driven: hasZ/hasM are read from gpkg_geometry_columns, never hardcoded.
GET .../points/query?returnZ=true
// service advertises the layer's true dimensionality
{
  "hasZ": true,
  "hasM": false,
  "geometryType": "esriGeometryPoint",
  "features": [{
    "geometry": { "x":-74.006, "y":40.712, "z":1500.5 }
  }]
}
In-App Screenshots

GeoPackage Manager & Data Engineering

VoltGrid desktop — GeoPackage Manager listing local .gpkg files and tables
GeoPackage Manager listing local .gpkg files and their tables
VoltGrid desktop — GeoPackage Manager Data Engineering tab
GeoPackage Manager Data Engineering tab, showing profiling and cleaning controls
Why it matters

Elevation is the whole point

Conductor attachment heights, buried duct banks, substation equipment levels, tower geometry — none of it lives on a flat plane.

🏙️

Substation digital twins

Capture equipment, bus work, and structure heights without losing the Z that defines them.

🚇

Underground distribution

Model duct banks, cables, and vaults at their true depth; navigate below the surface.

✈️

Drone inspection flights

Use Z + M for altitude and timestamp along 3D inspection trajectories over lines and substations.

⛏️

Poles & towers

Place structures with real vertical precision — base, attachment points, and top all at true height.

🏗️

BIM

Building information modeling for control houses and substations, where every floor and fixture has a height.

🚪

Storm-response staging

Sketch access routes, laydown yards, and egress in 3D for emergency operations.

The ESRI-compatible REST contract

A FeatureServer your existing tools already speak

All endpoints live under /api/featureserver/{datasetId} and follow the familiar ESRI FeatureServer shape — so the GIS tools your utility already runs can consume the edits.

Method & endpointReturnsNotes
GET /{ds}Service metadataCapabilities: Query, Create, Update, Delete, Editing, Sync
GET /{ds}/{layer}Layer schemahasZ/hasM from gpkg_geometry_columns
GET /{ds}/{layer}/queryFeaturesHonors returnZ
POST …/addFeaturesAdd resultsFull Z + M ingestion
POST …/updateFeaturesUpdate resultsPer-feature edits
POST …/deleteFeaturesDelete resultsBy OBJECTID
POST …/applyEditsTransactionalAtomic adds + updates + deletes

Capability strings reflect the implemented controller. Spatial filtering uses NetTopologySuite Envelope.Intersects client-side.

EsriGeometry3DConverter.cs
// OGC 12-128r12 standard GPKG blob envelope
// magic "GP" + flags + int32 SRID + ISO WKB
var writer = new WKBWriter {
    Strict = false,        // allow SRID header
    HandleSRID = true,
    HandleOrdinates = XYZM   // preserve Z & M
};
byte[] blob = writer.Write(ntsGeom);
Under the hood

Dependency-light, dependency-correct

A single converter does the heavy lifting — ESRI JSON ↔ NTS Geometry ↔ standard GPKG blob — with no heavyweight ORM. Everything runs locally, so field edits keep working in the truck, in the substation yard, or anywhere the backhaul is down. Bring corrected asset geometry back to the records your utility manages in GRID State.

  • Powered by NetTopologySuite 2.6.0 for 2.5D/3D geometry, WKB, and GPKG blobs.
  • Replaces prior stubs that returned empty blobs and POINT(0 0).
  • Dropped non-functional SpatiaLite ST_Intersects — filtering now via NTS envelopes.
  • Seeds a ready edit3d.gpkg (points = POINT Z, polygons = POLYGON Z) on first run.

Want 3D asset editing that keeps the Z?

Open the seeded edit3d dataset and start placing poles, spans, and structures at real elevations in seconds — fully offline.