h2gis
h2gis copied to clipboard
Add function to export and import geometry in TWKB encoding
Check the Tiny Well-known Binary specification
https://github.com/TWKB/Specification/blob/master/twkb.md
https://github.com/locationtech/jts/issues/246
Seems under the pipe https://github.com/locationtech/jts/pull/452
H2 does not use JTS for the GEOMETRY
data type, so it doesn't matter what is supported by JTS and what is not.
I thought about TWKB too, but it doesn't support SRID, it is designed to store decimal numbers (WKB uses IEEE 754 binary double precision values, just like double
in Java), so encoding of double
values with fractional part may be too long, and encoding and decoding of TWKB is quite expensive, it may actually reduce overall performance.
On the other hand, H2GIS can provide functions to export and import geometries in that format.
You are right. I have updated the title of the issue.
Available with JTS 1.19.0