Skip to content

Rust crate to converts lon/lat coordinates to slippy map tile format (OpenStreetMap/Google Map format)

License

Notifications You must be signed in to change notification settings

iott/slippy_map_tilenames

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

slippy_map_tilenames

A Rust crates that converts lon/lat coordinates to slippy map tile format. See this article by wiki.openstreetmap.org

Example

extern crate slippy_map_tilenames as smt;

fn main() {
    let t2l = smt::tile2lonlat(4376, 2932, 13); // (12.3046875, 45.460130637921)
    let l2t = smt::lonlat2tile(14.016667, 42.683333, 13); // (4414, 3019)    
    println!("Tile (4376, 2932) at zoom 13: {:?}", t2l);
    println!("lon 14.016667 E, lat 42.683333 N, at zoom 13: {:?}", l2t);
}

About

Rust crate to converts lon/lat coordinates to slippy map tile format (OpenStreetMap/Google Map format)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 100.0%