Commit graph

581 commits

Author SHA1 Message Date
Artem Pavlenko
4bf42fe2d7 + pass std::string argument by const& 2010-07-19 11:09:44 +00:00
Hermann Kraus
384c703557 Remove unneeded headers from save_map.{cpp,hpp} 2010-07-19 00:21:53 +00:00
Hermann Kraus
2c10bb68ef Enable metawriter_json to operate on any stream object. 2010-07-18 23:49:11 +00:00
Dane Springmeyer
7918184d13 add helper functions for recursively registering fonts, and ensure they match one of the known freetype2 supported fonts (by ext) - closes #559 2010-07-15 23:04:51 +00:00
Dane Springmeyer
4f9d6e135c output metadata about the searched plugin directories if a plugin cannot be found - closes #568 2010-07-15 21:11:41 +00:00
Artem Pavlenko
3d888515b3 + add feature caching support when multiple styles are
specified for the same layer. This should reduce
  I/O for complex styles and make multiple styles per
  layer a relatively cheap op. TODO: tweak memory_datasource
  impl.
2010-07-15 12:35:25 +00:00
Carlos López
d273101adc Added empty svg_renderer class, with unimplemented methods. 2010-07-15 05:32:31 +00:00
Dane Springmeyer
e670a1c44d only expose save_to_cairo_file if cairo support available 2010-07-14 18:30:22 +00:00
Artem Pavlenko
5c2f51504a + call base class ctor 2010-07-14 14:46:26 +00:00
Hermann Kraus
7e10a32503 Created a class for metawriter_properties. 2010-07-14 10:34:18 +00:00
Dane Springmeyer
ae0274cc6b make sure to only use mutexes if THREADING=multi/MAPNIK_THREADSAFE=True 2010-07-14 01:28:28 +00:00
Hermann Kraus
d5b0432dd7 Many metawriter improvements:
- Easier to configure
- Correct JSON output
- Handling more than one renderer run (writing pre-/postamble is no longer done in constructor/destructor)
- Collect all attributes required by metawriters
2010-07-12 15:27:33 +00:00
Hermann Kraus
9a0bcf23be Added basic infrastructure for metawriter and support for JSON output (limited to PointSymbolizer atm) 2010-07-06 00:37:05 +00:00
Artem Pavlenko
aa0e17afd1 + check cached connection status before returning.
if PQstatus(conn) == CONNECTION_BAD attempt to
  create a new one
+ expose "conect_timeout" PG connection parameter
  default to 4 sec
+ throw mapnik::datasource exception if connection
  is 'bad' in mapnik::features(..)
2010-07-02 11:42:35 +00:00
Artem Pavlenko
a486aed3af + fixed bug introduced in r1920
(ustring parser includes single quotes
   - remove extra '\'' in match/replace)
2010-06-28 22:43:35 +00:00
Artem Pavlenko
70b2453065 + add explicit support for shield displacement
(NOTE:text displacement is relative shield!)
2010-06-28 21:32:30 +00:00
Artem Pavlenko
9b3809443c + fix naming style in mapnik::Map 2010-06-25 15:23:35 +00:00
Artem Pavlenko
b472808fb1 + refactor remaining processing methods in agg_renderer
+ move agg_renderer.cpp to src/agg
2010-06-24 15:57:25 +00:00
Dane Springmeyer
04b7f5aa6f maintain boost 1.42/1.41 compatibility as lemexe appears to behave like no_skip with boost 1.42 2010-06-23 03:53:29 +00:00
Artem Pavlenko
8c8f303429 + allow empty strings in expressions e.g [name] <> '' 2010-06-22 13:06:55 +00:00
Artem Pavlenko
2f3a2c88b3 + css color grammar
- case-insensitive named colors
  - corrected alpha values parsing
2010-06-21 10:38:46 +00:00
Artem Pavlenko
ff9cca417b + use no_skip[] instead of lexeme[] directive
to avoid pre-skipping
2010-06-21 09:40:46 +00:00
Dane Springmeyer
e21f670275 add missing include 2010-06-21 03:18:07 +00:00
Dane Springmeyer
701c091f81 remove unneeded includes 2010-06-21 02:56:29 +00:00
Dane Springmeyer
0959f8ef16 + add support to polygon_patter_symbolizer for global pattern alignment in addition to local/feature (default) alignment - closes #203 2010-06-20 22:36:49 +00:00
Dane Springmeyer
182628e3ab + add filter_factor on mapnik::query and allow setting of factor for image scaling modes which demand high quality resampling - bilinear requires 2x, others in future like lanzcos may require 3-4x - addresses #563 2010-06-20 04:01:59 +00:00
Artem Pavlenko
e81b1abb8f + add implementation files 2010-06-18 15:39:57 +00:00
Artem Pavlenko
7bf6a35f5f + fixed clang++ issue 2010-06-18 15:39:40 +00:00
Artem Pavlenko
cf26db081a + refactor path expressions parser 2010-06-18 15:39:32 +00:00
Artem Pavlenko
ca59a06743 + move deg2rad to svg_path_commands 2010-06-18 15:39:23 +00:00
Artem Pavlenko
4c3eba876d + fixed template parameter shadowing (clang++) 2010-06-18 15:39:14 +00:00
Artem Pavlenko
5461739e64 + remove ununsed varialble 2010-06-18 15:38:59 +00:00
Artem Pavlenko
a5557d2b98 + qualify wit std:: 2010-06-18 15:38:52 +00:00
Artem Pavlenko
c99dff801a + forward decl mapnik::Map 2010-06-18 15:38:29 +00:00
Artem Pavlenko
79458691a1 + 'mutable' can't be applied to ref 2010-06-18 10:53:42 +00:00
Artem Pavlenko
e645338237 + use FT_Stroker to stroke glyphs outlines
(we can have outlined text now!)
+ allow fractional halo_radius
+ TODO: Rename halo_fill to stroke
               halo_radius to stroke-width
+ TODO: Implement proper 'halo' effect
2010-06-16 15:15:13 +00:00
Artem Pavlenko
e572b83d3a + fix copy ctor in symbolizer_with_image 2010-06-15 13:36:41 +00:00
Artem Pavlenko
9826cf98c5 + move opacity parameter to the base class
(symbolizer_with_image)
+ rename opacity to text_opacity in text_symbolizer
  to avoid name clashing
2010-06-15 12:27:42 +00:00
Artem Pavlenko
f43c36daad + separate state mutating svg ops from underlying data
to allow multi-threded access to svg symbols (SVG commands
  are stored in std::vector<vertex_type> )
2010-06-14 16:38:02 +00:00
Artem Pavlenko
6030efab50 + specialise svg parsers to expect const char* input 2010-06-14 13:18:17 +00:00
Artem Pavlenko
b309bba36e + pass scale_factor to feature_style_processor 2010-06-14 10:29:29 +00:00
Artem Pavlenko
03092107b6 + refactor path grammar to match svg spec close
+ ensure first 'moveto' command is always in
  absolute coordinates
  FIXME:probably better to modify path grammar
        to handle this.
+ vertex_stl_storage
2010-06-13 20:24:46 +00:00
Artem Pavlenko
68522e39fc + use agg implementation for circle,ellipse and rounded_rect 2010-06-13 13:45:59 +00:00
Artem Pavlenko
30b87400ca + put rasterizer def into sepatate header 2010-06-13 12:03:42 +00:00
Hermann Kraus
31a7aa2a3d Output a warning if a style is not found. 2010-06-13 00:19:56 +00:00
Artem Pavlenko
d272326d88 + skip <defs>...</defs> 2010-06-11 14:09:05 +00:00
Artem Pavlenko
b1b730d94c + add middle_point() method
+ fixed 'point' positioning
  in shield_symbolizer
2010-06-10 16:34:52 +00:00
Artem Pavlenko
11fad966cb + add experimental 'scale_factor'
TODO: discuss with Carlos and Dane if this is a better approach
  than having scale_factor in mapnik::Map object.
2010-06-10 14:12:20 +00:00
Artem Pavlenko
25dcebc18a + correct 'opacity' parameter logic
(SVG spec: 'The uniform opacity setting to be applied across an entire object.')
2010-06-10 14:12:12 +00:00
Artem Pavlenko
cc7e803b9d + preserve previously set alpha channel in
stroke/fill assignment so constructs like :
     style="fill-opacity:0.5;fill:blue"
  work with current svg attributes implementation
2010-06-10 14:12:03 +00:00
Artem Pavlenko
7e89bfa2db + don't use mapnik namespace inside mapnik namespace 2010-06-10 14:11:40 +00:00
Dane Springmeyer
f5ed4305f4 expose more coordinate transform methods, allowing projecting box2d<double> into screen coordinates at the same time as reprojecting geographical coordinates 2010-06-08 20:27:28 +00:00
Dane Springmeyer
13d192f255 add area method for polygon geometries, and avoid compiler warnings about intializations with -03 2010-06-08 20:01:40 +00:00
Artem Pavlenko
2b3858df07 + cache SVG marker bounding box 2010-06-08 10:16:31 +00:00
Artem Pavlenko
c500451cd8 + refactor SVG parsing/rendering code into separate logical units
to facilitate multi-threading:
    * SVG data (todo: enforce const)
    * SVG parsing/reading mutable
    * SVG rendering (read-only access to the data)
2010-06-08 10:16:22 +00:00
Artem Pavlenko
a47f6214a7 + add markers_symbolizer.cpp 2010-06-06 12:10:36 +00:00
Artem Pavlenko
bde8c1196f + add default ctor 2010-06-06 12:10:20 +00:00
Dane Springmeyer
9804e7e90d scons: make libjpeg dependency optional (still required by default) 2010-06-03 19:50:27 +00:00
Artem Pavlenko
7f36d5e2a1 + derive markers_symbilizer from symbolizer_with_image and inherit
filename expression and transformation matrix
2010-06-03 12:35:20 +00:00
Artem Pavlenko
f72fc9b397 + move transformation matrix to the parent class 2010-06-03 12:35:11 +00:00
Artem Pavlenko
b6414778d6 + add transformation matrix 2010-06-03 12:35:02 +00:00
Artem Pavlenko
246731874b + apply 'mapnik-format' to *.cpp *.hpp 2010-06-02 11:03:30 +00:00
Artem Pavlenko
484dce8943 + impl transform parameter (follow SVG spec) in point_symbolizer 2010-06-01 15:27:19 +00:00
Dane Springmeyer
a84b397f48 markers_converter.hpp was moved to markers_placement.hpp 2010-05-30 03:17:59 +00:00
Dane Springmeyer
89f6b32b76 apply patch from Herm from #553 adding support for markers_symbolizer to Cairo renderer, new placement finder, and fill/spacing/overlap options - works nicely with new svg support being tested against markers_symbolizer 2010-05-30 03:16:51 +00:00
Dane Springmeyer
74599581ec apply patch from Herm for fixing compilation on linux - closes #557 2010-05-30 02:16:49 +00:00
Artem Pavlenko
83c0f1ca59 + remove agg_svg_parser 2010-05-28 16:34:45 +00:00
Artem Pavlenko
a15e86e528 + add libxml2 based svg parser implementation 2010-05-28 16:34:34 +00:00
Artem Pavlenko
a0a21eaa59 + fixed transform mult order 2010-05-28 16:34:19 +00:00
Artem Pavlenko
6a5ea3f1a1 + SVG markers rendering 2010-05-27 14:21:31 +00:00
Artem Pavlenko
bb0ae08280 + marker_cache impl 2010-05-27 11:41:02 +00:00
Artem Pavlenko
823b7ba0fc + SVG markers initial import 2010-05-27 11:19:09 +00:00
Artem Pavlenko
e6e165f1e0 + use path-like geometries 2010-05-27 10:20:41 +00:00
Artem Pavlenko
b1195c79d7 + formatting 2010-05-27 10:20:25 +00:00
Artem Pavlenko
3ef0e2f789 + comment out exit() calls (todo: implement better
compile time tests)
2010-05-27 10:20:17 +00:00
Artem Pavlenko
c020acb3a7 + update attribute collector to handle 'orientation' 2010-05-27 10:19:55 +00:00
Artem Pavlenko
258a62616e + implement rotated text logic in placement finder 2010-05-27 10:19:47 +00:00
Artem Pavlenko
77c31e8643 + add orientation parameter
orientation="<expr>" e.g
  orientation="10+35" -> rotate by 45 degrees anti-clockwise
  (TODO: consider using standard SVG transform!)
2010-05-27 10:19:39 +00:00
Alberto Valverde
38e1570b8b added a max_value attribute to color_band to handle the case of the last band more gracefully 2010-05-06 07:21:11 +00:00
Dane Springmeyer
97eb553605 expose get/set for allow_overlap in MarkersSymbolizer 2010-04-15 21:47:44 +00:00
Artem Pavlenko
4b4967c351 + use doubles 2010-04-09 18:47:12 +00:00
Artem Pavlenko
5fcc311764 + add stroke-dashoffset property
+ replace <CssParameter name='xxx'>yyy</CssParameter>
   element with 'xxx'=yyy attribute
2010-04-09 18:46:25 +00:00
Artem Pavlenko
feb041f543 + apply formatting 2010-04-09 18:46:09 +00:00
Artem Pavlenko
61e423473e + no need for extra std::string alloc - we
+ can specialize css_parser to work with char*
+ (TODO: pass std::string const& as an input arg??)
2010-04-09 18:46:01 +00:00
Artem Pavlenko
f423a39bae + corrected name 2010-03-24 18:02:18 +00:00
Artem Pavlenko
1787c2b6ef + use <mapnik/filter_factory.hpp> 2010-03-24 18:02:02 +00:00
Artem Pavlenko
1a2b320252 + sanitize header inclusion a bit 2010-03-24 18:01:53 +00:00
Artem Pavlenko
666ff418dc + add specialization for bool in to_expression_string() 2010-03-24 18:01:45 +00:00
Marcin Rudowski
3426e7a0ac handle case of empty octrees. #540 2010-03-24 17:36:39 +00:00
Marcin Rudowski
8369278662 fixed color quantization in case of one color and transparency. #539 2010-03-24 17:19:33 +00:00
Alberto Valverde
c79865586b added an angle_mode attribute to GlyphSymbolizer to define the way the angle expression should be interpreted: as an azimuth or as a trigonometric angle 2010-03-22 11:21:17 +00:00
Alberto Valverde
a613dc6397 Created python binding to memory_datasource which can be added Features built programaticcaly. See tests for sample use until docs are done. #528 is almost closed. 2010-03-19 16:16:15 +00:00
Alberto Valverde
be9f874bbc added an attribute_collector visitor for glyph_symbolizer 2010-03-18 20:32:57 +00:00
Alberto Valverde
d098c98c5e pre-eliminary GlyphSymbolizer implementation. TODO: XML de/serializing. more tests. remove workaround mentioned in test 2010-03-18 20:05:08 +00:00
Alberto Valverde
31c3d20e43 modified the old arrow_symbolizer interface on glyph_symbolizer and documented it 2010-03-18 20:04:51 +00:00
Alberto Valverde
fc3a1beeef initial skeleton of glyph_symbolizer (coarsely ported from arrow_symbolizer). Mapnik compiles but symbolizer does nothing useful yet and is going to be heavily modified to make use of expressions to be general enough to be usable for purposes other than rendering arrows representing vector direction/intensity 2010-03-18 20:04:35 +00:00
Artem Pavlenko
d58b04a3f6 + use math stuff defined in <cmath> e.g std::pow std::log
+ fixed identation
+ use c++ style comments //
2010-03-17 21:39:36 +00:00
Artem Pavlenko
4aef1c46c1 + fix compiler warning 2010-03-17 21:39:28 +00:00
Artem Pavlenko
0fb695c133 + don't use C style casts 2010-03-17 21:39:20 +00:00
Artem Pavlenko
21dee82146 + remove mapnik:: classification from inside namespace mapnik {}
+ use c++ style casts!
2010-03-17 21:03:10 +00:00