From d5a8f89d64347ee71132ec901dfa7f07045ff47d Mon Sep 17 00:00:00 2001 From: Artem Pavlenko Date: Thu, 3 Jun 2010 12:35:31 +0000 Subject: [PATCH] +load transform parameter in markers_symbolizer --- src/load_map.cpp | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/load_map.cpp b/src/load_map.cpp index edcedb43f..6ebd6b62b 100644 --- a/src/load_map.cpp +++ b/src/load_map.cpp @@ -765,7 +765,8 @@ void map_parser::parse_markers_symbolizer( rule_type & rule, ptree const & sym ) std::string filename(""); optional file = get_opt_attr(sym, "file"); optional base = get_opt_attr(sym, "base"); - + optional transform_wkt = get_opt_attr(sym, "transform"); + if (file) { try @@ -806,9 +807,19 @@ void map_parser::parse_markers_symbolizer( rule_type & rule, ptree const & sym ) markers_symbolizer symbol(parse_path(filename)); optional opacity = get_opt_attr(sym, "opacity"); - if (opacity) { + if (opacity) + { // TODO !!!!! symbol.set_opacity( *opacity ); } + if (transform_wkt) + { + agg::trans_affine tr; + mapnik::svg::parse_transform(*transform_wkt,tr); + boost::array matrix; + tr.store_to(&matrix[0]); + symbol.set_transform(matrix); + } + optional c = get_opt_attr(sym, "fill"); if (c) symbol.set_fill(*c); optional spacing = get_opt_attr(sym, "spacing");