Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r77214 - trunk/libs/geometry/example_extensions/gis/projections
From: barend.gehrels_at_[hidden]
Date: 2012-03-04 07:38:03


Author: barendgehrels
Date: 2012-03-04 07:38:02 EST (Sun, 04 Mar 2012)
New Revision: 77214
URL: http://svn.boost.org/trac/boost/changeset/77214

Log:
[geometry] updates examples for: "namespace projection is renamed projections to avoid clash with class projection. Suggested by Krzysztof Czainski"
NOTE: previous commit message was not complete, it should also read "and patch provided Krzysztof Czainski"
Text files modified:
   trunk/libs/geometry/example_extensions/gis/projections/p01_projection_example.cpp | 4 ++--
   trunk/libs/geometry/example_extensions/gis/projections/p02_projfactory_example.cpp | 6 +++---
   trunk/libs/geometry/example_extensions/gis/projections/p03_projmap_example.cpp | 4 ++--
   3 files changed, 7 insertions(+), 7 deletions(-)

Modified: trunk/libs/geometry/example_extensions/gis/projections/p01_projection_example.cpp
==============================================================================
--- trunk/libs/geometry/example_extensions/gis/projections/p01_projection_example.cpp (original)
+++ trunk/libs/geometry/example_extensions/gis/projections/p01_projection_example.cpp 2012-03-04 07:38:02 EST (Sun, 04 Mar 2012)
@@ -21,14 +21,14 @@
     using namespace boost::geometry;
 
     // Initialize projection parameters
- projection::parameters par = projection::init("+ellps=WGS84 +units=m");
+ projections::parameters par = projections::init("+ellps=WGS84 +units=m");
 
     // Construct a Robinson projection, using specified point types
     // (This delivers a projection without virtual methods. Note that in p02 example
     // the projection is created using a factory, which delivers a projection with virtual methods)
     typedef model::ll::point<degree> point_ll_deg;
     typedef model::d2::point_xy<double> point_xy;
- projection::robin_spheroid<point_ll_deg, point_xy> prj(par);
+ projections::robin_spheroid<point_ll_deg, point_xy> prj(par);
 
     // Define Amsterdam / Barcelona in decimal degrees / degrees/minutes
     point_ll_deg amsterdam = parse<point_ll_deg>("52.4N", "5.9E");

Modified: trunk/libs/geometry/example_extensions/gis/projections/p02_projfactory_example.cpp
==============================================================================
--- trunk/libs/geometry/example_extensions/gis/projections/p02_projfactory_example.cpp (original)
+++ trunk/libs/geometry/example_extensions/gis/projections/p02_projfactory_example.cpp 2012-03-04 07:38:02 EST (Sun, 04 Mar 2012)
@@ -22,7 +22,7 @@
     using namespace boost::geometry;
 
     // Initialize projection parameters. For construction using a factory the projection name is required.
- projection::parameters par = projection::init("+proj=robin +ellps=WGS84 +units=m");
+ projections::parameters par = projections::init("+proj=robin +ellps=WGS84 +units=m");
 
     // Construct the specified projection, using specified point types
     // Note that this is the only difference from p01_projection_example. It constructs a projection
@@ -30,8 +30,8 @@
     // convenience we use a boost shared pointer here.
     typedef model::ll::point<degree> point_ll_deg;
     typedef model::d2::point_xy<double> point_xy;
- projection::factory<point_ll_deg, point_xy> fac;
- boost::shared_ptr<projection::projection<point_ll_deg, point_xy> > prj(fac.create_new(par));
+ projections::factory<point_ll_deg, point_xy> fac;
+ boost::shared_ptr<projections::projection<point_ll_deg, point_xy> > prj(fac.create_new(par));
 
     // Define Amsterdam / Barcelona in decimal degrees / degrees/minutes
     point_ll_deg amsterdam(longitude<>(5.9), latitude<>(52.4));

Modified: trunk/libs/geometry/example_extensions/gis/projections/p03_projmap_example.cpp
==============================================================================
--- trunk/libs/geometry/example_extensions/gis/projections/p03_projmap_example.cpp (original)
+++ trunk/libs/geometry/example_extensions/gis/projections/p03_projmap_example.cpp 2012-03-04 07:38:02 EST (Sun, 04 Mar 2012)
@@ -61,7 +61,7 @@
     std::vector<model::polygon<point_xy> > xy_polygons;
 
     // Declare transformation strategy which contains a projection
- projection::project_transformer
+ projections::project_transformer
         <
             point_ll_deg,
             point_xy
@@ -109,7 +109,7 @@
 
     // Create the background
     boost::geometry::model::box<svg_point> box;
- boost::geometry::assign(box, 0, 0, 800, 600);
+ boost::geometry::assign_values(box, 0, 0, 800, 600);
     out << boost::geometry::svg(box, "fill:rgb(0,0,255)") << std::endl;
 
     for (std::vector<model::polygon<point_xy> >::const_iterator it = xy_polygons.begin();


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk