Skip to content

🌍 Go package to convert coordinates from Lambert to WGS84

License

Notifications You must be signed in to change notification settings

yageek/lambertgo

Repository files navigation

lambertgo

Build Status Coverage Status GoDoc Report Cart

A simple Go package to convert coordinates in Lambert projections system to GPS WGS84 coordinates. It is based on the IGN algorithms and methods

Install

go get gopkg.in/yageek/lambertgo.v1

Usage

import lgo "github.com/yageek/lambertgo"
import "fmt"

//Declares origin point
var point *lgo.Point= &lgo.Point{994272.661,113467.422,0,lgo.Meter}

//Converts pointOrg in Lambert Zone 1 to WGS84 - Results in Radian
point.ToWGS84(lgo.LambertI)

//Converts to Degree
point.ToDegree()

fmt.Printf("Latitude:%.5f - Longitude:%.5f",point.Y,point.X)
import lgo "github.com/yageek/lambertgo"
import "fmt"

//Declares origin point
var point *lgo.Point= &lgo.Point{2.228389, 48.824054,0,lgo.Degree}

//Converts to Radian
point.ToRadian()

//Converts pointOrg in WGS84 to Lambert Zone 1  - Results in Meter
point.ToLambert(lgo.LambertI)


fmt.Printf("X:%.5f - Y:%.5f",point.X,point.Y)

About

🌍 Go package to convert coordinates from Lambert to WGS84

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages