Description
Package go-kml provides convenince methods for creating and writing KML documents.
See https://godoc.org/github.com/twpayne/go-kml.
Example:
go-kml alternatives and similar packages
Based on the "GIS" category.
Alternatively, view go-kml alternatives based on common mentions on social networks and blogs.
-
go-geom
Package geom implements efficient geometry types for geospatial applications. -
polyline
Package polyline implements a Google Maps Encoding Polyline encoder and decoder. -
UTM
Bidirectional UTM-WGS84 converter for golang :earth_africa: :globe_with_meridians: -
go-gpx
Package gpx provides convenience types for reading and writing GPX files. -
go-sypexgeo
SypexGeo library for Go (provides access data from SypexGeo IP database files)
InfluxDB - Power Real-Time Data Analytics at Scale
Do you think we are missing an alternative of go-kml or a related project?
Popular Comparisons
README
go-kml
Package kml
provides convenience methods for creating and writing KML documents.
Key Features
- Simple API for building arbitrarily complex KML documents.
- Support for all KML elements, including Google Earth
gx:
extensions. - Compatibilty with the standard library
encoding/xml
package. - Pretty (neatly indented) and compact (minimum size) output formats.
- Support for shared
Style
andStyleMap
elements. - Simple mapping between functions and KML elements.
- Convenience functions for using standard KML icons.
- Convenience functions for spherical geometry.
Example
func ExampleKML() {
k := kml.KML(
kml.Placemark(
kml.Name("Simple placemark"),
kml.Description("Attached to the ground. Intelligently places itself at the height of the underlying terrain."),
kml.Point(
kml.Coordinates(kml.Coordinate{Lon: -122.0822035425683, Lat: 37.42228990140251}),
),
),
)
if err := k.WriteIndent(os.Stdout, "", " "); err != nil {
log.Fatal(err)
}
}
Output:
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2">
<Placemark>
<name>Simple placemark</name>
<description>Attached to the ground. Intelligently places itself at the height of the underlying terrain.</description>
<Point>
<coordinates>-122.0822035425683,37.42228990140251</coordinates>
</Point>
</Placemark>
</kml>
There are more examples in the documentation corresponding to the examples in the KML tutorial.
Subpackages
icon
Convenience functions for using standard KML icons.sphere
Convenience functions for spherical geometry.
License
MIT
*Note that all licence references and agreements mentioned in the go-kml README section above
are relevant to that project's source code only.