Closed mdsumner closed 4 years ago
Also
https://gdal.org/development/rfc/rfc64_triangle_polyhedralsurface_tin.html
wkt_list = ['POLYHEDRALSURFACE (((0 0 0,0 0 1,0 1 1,0 1 0,0 0 0)),((0 0 0,0 1 0,1 1 0,1 0 0,0 0 0)),((0 0 0,1 0 0,1 0 1,0 0 1,0 0 0)),((1 1 0,1 1 1,1 0 1,1 0 0,1 1 0)),((0 1 0,0 1 1,1 1 1,1 1 0,0 1 0)),((0 0 1,1 0 1,1 1 1,0 1 1,0 0 1)))',
'TIN (((0 0 0,0 0 1,0 1 0,0 0 0)),((0 0 0,0 1 0,1 1 0,0 0 0)))',
'TRIANGLE ((48 36 84,32 54 64,86 11 54,48 36 84))' ]
internal tri_to_sf function though I can't imagine any practical use ...
tri_to_sf(copy_down(DEL(minimal_mesh), "a"))
Geometry set for 20 features
geometry type: TIN
dimension: XYZ
bbox: xmin: 0 ymin: 0 xmax: 1.23 ymax: 1
z_range: zmin: 1 zmax: 2
CRS: NA
First 5 geometries:
TRIANGLE Z ((0.2 0.2 1, 0.69 0 1, 0.5 0.2 1))
TRIANGLE Z ((0.69 0 1, 0.2 0.2 1, 0 0 1))
TRIANGLE Z ((0.2 0.2 1, 0.5 0.2 1, 0.5 0.4 1))
TRIANGLE Z ((0 0 1, 0.2 0.2 1, 0.2 0.4 1))
TRIANGLE Z ((0 1 1, 0.2 0.4 1, 0.3 0.6 1))
from https://gis.stackexchange.com/questions/22809/representing-a-tin-in-geojson