[ANN] [Geospatial] New set of Go bindings for GEOS
99 views
Skip to first unread message
twp...@gmail.com
unread,
Jun 20, 2021, 1:37:48 PM6/20/21
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to golang-nuts
GEOS is the standard geometry library that underpins PostGIS and much of the open source geospatial world.
https://github.com/twpayne/go-geos is a new set of Go bindings for GEOS that make it easy to use GEOS geometries in your Go applications. Features include:
Fluent Go API.
Low-level Context, CoordSeq, Geom, and PrepGeom types provide access to all GEOS methods.
High-level geometry.Geometry type implements all GEOS functionality and many standard Go interfaces, including database/sql/driver.Valuer and database/sql.Scanner (WKB) for PostGIS database integration and encoding/json.Marshaler and encoding/json.Unmarshaler (GeoJSON). See the PostGIS example for a demonstration of the use of these interfaces.
Concurrency-safe. go-geos uses GEOS's threadsafe *_r functions under the hood, with locking to ensure safety, even when used across multiple goroutines. For best performance, use one geos.Context per goroutine.
Caching of geometry properties to avoid cgo overhead.