Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Nov 23, 2021. It is now read-only.

tmatilai/iof-xml-coords

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

iof-xml-coords

npm version

Convert the coordinates in an IOF-XML file to WGS84.

The conversion might be needed if the XML file is exported from e.g. Condes using a map with a local coordinate system.

Installation

npm install -g iof-xml-coords

Usage

iof-xml-coords [-s <projection>] <file>

Arguments

  • file - The source file (reads from STDIN if not specified)

Options

  • -s, --src <projection> - The source projection (default: "GK25FIN")
  • -h, --help - Display help
  • -V, --version - Output the version number

Projection

Currently supported projections:

Other projections can be specified in the Proj4js format. These can be found in for example epsg.io.

Besides the command line option, the projection can also be passed via the IOF_SRC environment variable.

Examples

Convert "ETRS89 / TM35FIN" coordinates from coursedata.xml to coursedata_wgs84.xml:

iof-xml-coords -s TM35FIN coursedata.xml > coursedata_wgs84.xml

Convert "ETRS89 / UTM zone 35N" (EPSG:3047) coordinates. Output to STDOUT.

export IOF_SRC='+proj=utm +zone=35 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs'

iof-xml-coords < iof.xml

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/tmatilai/iof-xml-coords. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The software is available as open source under the terms of the ISC License.

About

Convert the coordinates in an IOF-XML file to WGS84

Resources

Stars

Watchers

Forks

Packages

No packages published