diff --git a/include/mapnik/svg/svg_generator.hpp b/include/mapnik/svg/svg_generator.hpp index df5972ecb..7a120ada6 100644 --- a/include/mapnik/svg/svg_generator.hpp +++ b/include/mapnik/svg/svg_generator.hpp @@ -48,7 +48,7 @@ namespace mapnik { namespace svg { typedef svg::svg_root_attributes_grammar root_attributes_grammar; typedef svg::svg_rect_attributes_grammar rect_attributes_grammar; - typedef svg::svg_path_data_grammar path_data_grammar; + // typedef svg::svg_path_data_grammar path_data_grammar; typedef svg::svg_path_attributes_grammar path_attributes_grammar; typedef svg::svg_path_dash_array_grammar path_dash_array_grammar; diff --git a/include/mapnik/svg/svg_output_grammars.hpp b/include/mapnik/svg/svg_output_grammars.hpp index ead6e3836..fceccd0f8 100644 --- a/include/mapnik/svg/svg_output_grammars.hpp +++ b/include/mapnik/svg/svg_output_grammars.hpp @@ -26,6 +26,7 @@ // mapnik #include #include +//#include #include #include @@ -108,7 +109,7 @@ BOOST_FUSION_ADAPT_STRUCT( * required by Karma to be recognized as a container of * attributes for output generation. */ -namespace boost { namespace spirit { namespace traits { +/*namespace boost { namespace spirit { namespace traits { template <> struct is_container @@ -118,29 +119,33 @@ namespace boost { namespace spirit { namespace traits { template <> struct container_iterator { - typedef mapnik::geometry_type::iterator type; + typedef mapnik::geometry_iterator type; }; template <> struct begin_container { - static mapnik::geometry_type::iterator + static mapnik::geometry_iterator call(mapnik::geometry_type const& g) { - return g.begin(); + double* x; + double* y; + unsigned cmd = g.vertex(x, y); + + return mapnik::geometry_iterator(g, mapnik::geometry_iterator::iter_value(*x, *y, cmd)); } }; template <> struct end_container { - static mapnik::geometry_type::iterator + static mapnik::geometry_iterator call(mapnik::geometry_type const& g) { - return g.end(); + return mapnik::geometry_iterator(g); } }; -}}} + }}}*/ namespace mapnik { namespace svg { @@ -194,15 +199,17 @@ namespace mapnik { namespace svg { struct svg_path_data_grammar : karma::grammar { typedef path_coordinate_transformer coordinate_transformer; - typedef mapnik::vertex_vector2::vertex_type vertex_type; - typedef mapnik::vertex_vector2::value_type vertex_component_type; + //typedef mapnik::vertex_vector2::vertex_type vertex_type; + typedef mapnik::geometry_type::vertex_type vertex_type; + //typedef mapnik::vertex_vector2::value_type vertex_component_type; + typedef mapnik::geometry_type::value_type vertex_component_type; explicit svg_path_data_grammar(PathType const& path_type) : svg_path_data_grammar::base_type(svg_path), path_type_(path_type), ct_(path_type) { - using karma::int_; + /* using karma::int_; using karma::double_; using karma::_1; using karma::_a; @@ -231,7 +238,7 @@ namespace mapnik { namespace svg { path_vertex_transformed_x = double_[_1 = _a][bind(&coordinate_transformer::current_x, &ct_, _a)]; - path_vertex_transformed_y = double_[_1 = _a][bind(&coordinate_transformer::current_y, &ct_, _a)]; + path_vertex_transformed_y = double_[_1 = _a][bind(&coordinate_transformer::current_y, &ct_, _a)];*/ } karma::rule svg_path; @@ -242,7 +249,7 @@ namespace mapnik { namespace svg { PathType const& path_type_; coordinate_transformer ct_; - }; + }; template struct svg_path_attributes_grammar : karma::grammar diff --git a/include/mapnik/svg_renderer.hpp b/include/mapnik/svg_renderer.hpp index 3cd2562a2..6ec80cef7 100644 --- a/include/mapnik/svg_renderer.hpp +++ b/include/mapnik/svg_renderer.hpp @@ -92,7 +92,7 @@ namespace mapnik * @brief Overload that process the whole set of symbolizers of a rule. * @return true, meaning that this renderer can process multiple symbolizers. */ - bool process(rule_type::symbolizers const& syms, + bool process(rule::symbolizers const& syms, Feature const& feature, proj_transform const& prj_trans); diff --git a/src/svg/svg_generator.cpp b/src/svg/svg_generator.cpp index 4e75f1bc0..29340aed8 100644 --- a/src/svg/svg_generator.cpp +++ b/src/svg/svg_generator.cpp @@ -69,13 +69,14 @@ namespace mapnik { namespace svg { template void svg_generator::generate_path(path_type const& path, path_output_attributes const& path_attributes) { - path_data_grammar data_grammar(path); + /* path_data_grammar data_grammar(path); path_attributes_grammar attributes_grammar; path_dash_array_grammar dash_array_grammar; karma::generate(output_iterator_, lit("\n"), path_attributes); + */ } template class svg_generator >;