Geo::OSM::Render::Projection - Project OSM latitudes and longitudes into x, y coordinate pairs to be rendered by Geo::OSM::Render.
SYNOPSIS
This is an abstract base class. So, I am hard pressed to write a synopsis here.
OVERVIEW
Before OpenStreetMap data can be rendered, the OSM coordinates must be projected into a suitable x/y coordinate system. Descendents of this class should (must...) provide the conversion function <lat_lon_to_x_y
> which performce this projection.
Currently, two classes are derived from this class: Geo::OSM::Render::Projection::CH_LV03 and Geo::OSM::Render::Projection::Ident.
METHODS
new
my $proj = Geo::OSM::Render::Projection->new();
Create an instance of a projection. Use it in a derived class.
lat_lon_to_x_y
my ($x, $y) = $projection->lat_lon_to_x_y($lat, $lon);
Because this is an abstract base class, calling this method on <Geo::OSM::Render::Projection
> just croaks.
AUTHOR
René Nyffenegger <rene.nyffenegger at adp-gmbh.ch>
COPYRIGHT AND LICENSE Copyright © 2017 René Nyffenegger, Switzerland. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of the the Artistic License (2.0). You may obtain a copy of the full license at: http://www.perlfoundation.org/artistic_license_2_0
Source Code
The source code is on github. Meaningful pull requests are welcome.