It is a Go binding for GEOS
- GEOS Library installed
- Get source code with command
go get github.com/warrenwyf/go-geos/geos
- (Optional) Change
CFLAGS
andLDFLAGS
in source code to your library path if necessary
$ brew install geos
$ sudo apt-add-repository -y ppa:ubuntugis/ubuntugis-unstable
$ sudo apt-get update
$ sudo apt-get install libgeos-dev libgeos-3.4.2
package main
import (
"github.com/warrenwyf/go-geos/geos"
)
func main() {
geom := geos.CreatePoint(0, 0)
wkt := geom.Buffer(10).ToWKT()
}