Commit graph

1213 commits

Author SHA1 Message Date
Dane Springmeyer
ac3e43e5a4 support faster wgs84->merc transforms, a very common reprojection scenario in web mapping - added benefit of this approach is easy clipping for robust handling of out of bounds mercator coords - closes #839 2011-09-12 02:10:58 +00:00
Dane Springmeyer
0ec7ef6d46 renderers can now report to image if any features have been rendered via im.painted(), and im.background now uses boost optional to allow easy detection of whether a background has been set - closes #875 2011-09-11 06:24:26 +00:00
Dane Springmeyer
3ad234bce8 early return from rendering text labels if polygon width does not meet minimum threashold - refs #840 2011-09-10 08:50:07 +00:00
Dane Springmeyer
ae9dedeb27 add line_symbolizer cpp 2011-09-09 23:46:39 +00:00
Dane Springmeyer
67d7a3a6f0 add alternative line rasterizer that can be enabled to draw faster lines at the expense of dropping short geometries - for thin lines has nicer look but should not be used with think lines - refs #873 2011-09-09 23:45:49 +00:00
Dane Springmeyer
5e704d4b0b maintain boost 1.42 compatibility by disabling new wkt parser for boost <= 1.46 2011-09-09 09:26:11 +00:00
Artem Pavlenko
aba5f21936 + applied patch from itayperl (bidi-mirroring-SVN-r3110.patch) 2011-09-08 15:08:17 +00:00
Artem Pavlenko
53b50c871c + modify WKT parser to work with ptr_vector<geometry_type>
+ fix memory leaks in wkt_grammar
+ add support for GEOMETRYCOLLECTION
2011-09-08 11:52:51 +00:00
Dane Springmeyer
31103e4ea8 apply "fast math" patch from Herm for using faster trigonometric functions for placement - refs #840 2011-09-08 03:47:56 +00:00
Artem Pavlenko
91c315aee7 applied patch from kkaefer (gist: 9e0d59a418f8ca653d26) 2011-09-07 20:01:01 +00:00
Artem Pavlenko
02c143895d + refactor palette stuff a bit
TODO: We need to change save_to_file|string interface
  to avoid passing dummy rgba_palette objects.
2011-09-07 15:01:25 +00:00
Dane Springmeyer
25196e3a8e revise png palette api by removing default arguments to ensure no temporary references 2011-09-07 00:45:18 +00:00
Dane Springmeyer
4015d0c13b warn if a layer has no style 2011-09-05 19:32:24 +00:00
Dane Springmeyer
aa5cfad4b7 add minimum-path-length to text_symbolizer - closes #865 2011-09-04 17:33:48 +00:00
Hermann Kraus
a4475b9ac8 Remove redundant trigonometric calculations to improve performance (#840). 2011-09-02 14:44:11 +00:00
Dane Springmeyer
914ad079ec add back AlsoFilter support - re-closes #820 2011-09-02 13:10:14 +00:00
Dane Springmeyer
a966dfd7f9 scons: ensure cairo flags are set before any special handling of libmapnik env source compile flags 2011-09-01 21:04:41 +00:00
Dane Springmeyer
a8cc348483 rendering stats: print srs values when warning about reprojection 2011-09-01 15:28:08 +00:00
Dane Springmeyer
8e94bf9188 expose first pass at rendering statistics via build option 'RENDERING_STATS' - refs #780 2011-09-01 05:14:25 +00:00
Dane Springmeyer
2052e072c1 remove debug prints and lessen unneeded indenting - no functional change 2011-09-01 04:49:59 +00:00
Dane Springmeyer
d4af1dbfaa add needed include 2011-09-01 01:18:10 +00:00
Dane Springmeyer
b2dc2fa6d2 move feature_style_processor to cpp 2011-09-01 00:44:27 +00:00
Dane Springmeyer
6003a647f3 add needed include for evaluating expressions to prepare for moving feature_style_processor to cpp file 2011-09-01 00:43:46 +00:00
Dane Springmeyer
a013cd5032 add support for fixed color palettes when encoding to png 2011-08-31 02:28:14 +00:00
Dane Springmeyer
477c317753 fix typo 2011-08-31 00:25:03 +00:00
Dane Springmeyer
ce09895a53 add cache-features of list of attributes not to warn about on layer 2011-08-30 23:10:10 +00:00
Dane Springmeyer
9e87c9f914 apply patch from Peter Körner adding AlsoFilter functionality - closes #820 2011-08-30 17:38:27 +00:00
Dane Springmeyer
22c39d91ba scons: rename all SConscript files to more friendly name of 'build' with a python extension for quick syntax detection in editors 2011-08-30 05:32:01 +00:00
Dane Springmeyer
2abe4d8960 don't muffle any exceptions during load_map 2011-08-29 23:51:15 +00:00
Dane Springmeyer
2c75feed65 scons: fix bug that propagated libmapnik CXXFLAGS too liberally (in this case to plugins) 2011-08-29 23:01:33 +00:00
Dane Springmeyer
6cb31bd109 scons: better propagation of libmapnik build flags to command line utilities and mapnik-config - also remove conditional flags on specific cairo rendering .cpp files as this was not working right - closes #837 2011-08-29 21:12:22 +00:00
Dane Springmeyer
22f6c9f01a add a few direct includes 2011-08-29 21:07:45 +00:00
Dane Springmeyer
8a5e7b9f9a correctly initalize markers_symbolizer default values - avoid segfaul in carto-parser 2011-08-28 16:49:02 +00:00
Dane Springmeyer
caf541d87e add support for controlling zlib compression level and strategy when encoding to png - patch from kkaefer - closes #841 2011-08-26 05:58:21 +00:00
Dane Springmeyer
1231b96872 link to boost system on all platforms, if available - fixes debian/ubuntu compiles with packaged boost - closes #823 2011-08-17 14:32:08 +00:00
Dane Springmeyer
2922a0db02 scons: don't link agg if runtiming linking is static 2011-08-13 03:25:07 +00:00
Dane Springmeyer
da834706c6 scons: start condensing more global variables and improve support for static linking 2011-08-12 20:01:09 +00:00
Dane Springmeyer
3b424e3767 allow compile against ICU 4.0 - needed to be able to link against osx provided libicucore.dylib 2011-08-11 21:13:55 +00:00
Dane Springmeyer
af62ad9c27 scons: collect and propogate the libs used to link libmapnik 2011-08-11 21:11:11 +00:00
Dane Springmeyer
82ac99611e add LINKING option to control whether libmapnik is build static or shared and RUNTIME_LINK options to trigger dependency flags to compile against static libs 2011-08-11 19:14:00 +00:00
Dane Springmeyer
731bc4e99c fix intialization order warning 2011-08-04 19:05:28 +00:00
Dane Springmeyer
81bf8b3d06 expose the name2file mapping of font family/style and font file publically so apps can ask mapnik where a given font face was found on the filesystem 2011-07-29 18:03:45 +00:00
Hermann Kraus
53e0b22c2b Added metawriter helper function. 2011-07-28 22:59:05 +00:00
Hermann Kraus
607f4e7c99 Applied patch from Peter Körner (with small changes). 2011-07-23 00:11:01 +00:00
Dane Springmeyer
85804b797f typo 2011-07-16 15:45:40 +00:00
Hermann Kraus
08f1a71e4b Fix default value. 2011-07-16 12:40:33 +00:00
Hermann Kraus
4a7249ca50 Actually use the new pixel coordinate function. 2011-07-16 12:32:39 +00:00
Hermann Kraus
8bb6df1a07 Optionally output JSON data with pixel coordinates. 2011-07-16 12:24:52 +00:00
Dane Springmeyer
abcba2bc34 #759 is fixed, revert r3008 2011-07-16 00:25:30 +00:00
Robert Coup
8e8f43e50f Fix incorrect blending of rasters with alpha channel. Use pixfmt_rgba32_plain rather than pixfmt_rgba32, and undo old changes to blender_rgba<>::blender_pix which aren't needed anymore. Thanks @rfw, @cdestigter, @albertov [fixes #759] 2011-07-15 03:59:44 +00:00
Dane Springmeyer
7b871210c7 use namespace to avoid potential clash 2011-07-09 00:28:41 +00:00
Dane Springmeyer
f156e147d3 rollback to using pre r2543 methods for bilinear scaling (non agg) - to be used until #759 is resolved 2011-07-07 21:24:17 +00:00
Dane Springmeyer
7e1c4a58b0 add code comment about ltdl global advise usage in relation to #790 2011-07-05 23:50:30 +00:00
Dane Springmeyer
3bbd4b9b3a remove uneeded semicolon 2011-07-05 23:39:50 +00:00
Dane Springmeyer
c4fa04cdad don't suppress exception in mapnik::color constructor when init from a string 2011-07-05 23:01:51 +00:00
Dane Springmeyer
476e04c4c7 add gamma to polygon-pattern-symbolizer, useful for avoiding AA affects at tile edges so that global patterns can have seamless alignment 2011-06-28 22:37:35 +00:00
Dane Springmeyer
4dde8e8d9e warning if non svg file passed to markers_symbolizer 2011-06-24 20:34:21 +00:00
Dane Springmeyer
e94667a8ae use std::string 2011-06-24 00:53:00 +00:00
Dane Springmeyer
45965381af throw if we encounter a font file which lacks any referencable names (freetype family_name and style_name) making it basically invalid 2011-06-24 00:51:21 +00:00
Dane Springmeyer
086138dedc switch back to using grid width/height to allow for variable size grid to be rendered (purely for testing) 2011-06-16 18:08:04 +00:00
Dane Springmeyer
5f53246337 fix bug in width/height of transform in grid_renderer 2011-06-16 16:48:30 +00:00
Dane Springmeyer
1829093fc9 copy string, don't get reference from boost::filesystem::path 2011-06-13 21:42:44 +00:00
Artem Pavlenko
4a72a7d680 + fix color(std::string const& ) ctor to initialize r,g,b,a.
+ impl eq ops using boost::equality_comparable.
+ output alpha in to_hex_string if not 255.
2011-06-07 16:14:02 +00:00
Dane Springmeyer
104dd25a94 grid_renderer: only clamp markers size if initial grid resolution is reduced 2011-06-04 00:20:29 +00:00
Dane Springmeyer
7da40e3700 grid_renderer: rename step->resolution 2011-06-04 00:16:16 +00:00
Dane Springmeyer
840bb52de6 avoid compiler warning 2011-06-01 18:53:47 +00:00
Dane Springmeyer
c230ed6733 add alternative bbox forward/inverse functions 2011-05-31 22:38:15 +00:00
Hermann Kraus
8474976353 Prepare for merging "text_placement_info" and "placement". 2011-05-30 01:16:21 +00:00
Hermann Kraus
de089f0d68 Add alignment to text_placement_info. 2011-05-29 22:33:41 +00:00
Dane Springmeyer
1d07c81316 add missed commits to complete the support for map 'base' 2011-05-25 23:51:40 +00:00
Dane Springmeyer
7a17c7e597 load_map_from_string has always accepted a base path argument to drive the interpretation of relative paths in the stylesheet when loaded in memory- this really should be a full map property so that it can be known on the map object after parsing and changed if the map is saved to a new location 2011-05-25 23:48:07 +00:00
Dane Springmeyer
ba15947a4f add Projection.expanded() function to ask proj4 what its internal, normalized definition looks like (useful only for debugging) 2011-05-17 19:05:15 +00:00
Dane Springmeyer
e119dc503c move to binary grid renderer for non-aa output rather than setting gamma on aa renderer 2011-05-17 06:24:49 +00:00
Dane Springmeyer
3469c20f1c adapt to new svg renderer template 2011-05-17 06:19:41 +00:00
Dane Springmeyer
b578c02c54 make renderer type a template argument of agg svg renderer 2011-05-17 06:18:06 +00:00
Dane Springmeyer
9458e2d890 stroke-dash-offet -> stroke-dash-offset (spelling)- #762 2011-05-17 00:33:24 +00:00
Alberto Valverde
d5dafdc2be reverted patch which was committed by mistake 2011-05-12 18:11:16 +00:00
Alberto Valverde
0e0c4aa82c integrated test case from #759 2011-05-12 18:09:03 +00:00
Dane Springmeyer
aeb1b7f963 renable previous (non-agg) internal bilinear scaling method for testing #759a 2011-05-12 16:43:23 +00:00
Hermann Kraus
1cff36576c Remove empty files. 2011-05-11 12:04:18 +00:00
Hermann Kraus
f001d46efc Fix build errors introduced by r2889. 2011-05-11 00:49:52 +00:00
Dane Springmeyer
90fbd6a204 use boost::make_shared to avoid explicit new and ensure fast and exception safe allocation 2011-05-10 21:09:54 +00:00
Artem Pavlenko
53c8225246 + Shield/text misalignment patch from Ldp
( http://trac.mapnik.org/ticket/739 )
2011-05-10 21:05:40 +00:00
Artem Pavlenko
3bef010056 + move feature_factory.hpp include to impl file 2011-05-09 13:52:06 +00:00
Artem Pavlenko
498809dde8 + don't scale shield (scale_factor is applied in agg_renderer<T>::render_marker) 2011-05-09 13:51:50 +00:00
Dane Springmeyer
1b1bd4b02e sync cairo with agg renderer after r2876 2011-05-06 00:36:09 +00:00
Dane Springmeyer
f925c395e5 apply patch from kevin for #756 2011-05-06 00:33:49 +00:00
Dane Springmeyer
1070b293ad tabs -> spaces 2011-05-04 15:53:36 +00:00
Dane Springmeyer
bae28f509e wrap raster_colorizer in mapnik ns and remove uneeded includes 2011-05-04 05:19:58 +00:00
Dane Springmeyer
37118c6d5f ensure valid attributes on the RasterSymbolizer and RasterColorizer, warning if not 2011-05-04 01:57:37 +00:00
Dane Springmeyer
0a278e7c49 slighly more restrictive default max_char_angle_delta 2011-05-04 01:53:20 +00:00
Dane Springmeyer
d05b0c539f apply major refactor of RasterColorizer by ben moores from https://github.com/BenMoores/mapnik-trunk/wiki/RasterColorizer - closes #523 2011-05-04 00:20:17 +00:00
Dane Springmeyer
2c275729b1 initialize variables 2011-05-03 21:38:35 +00:00
Dane Springmeyer
adb44a6ec2 account for scaling and alpha of bitmap images in grid_renderer 2011-05-02 22:33:11 +00:00
Dane Springmeyer
e69f17eb35 add ability to pass a scaling ratio just to the affine scaling - needed by grid_renderer 2011-05-02 22:30:50 +00:00
Dane Springmeyer
c413d67b82 sync cairo's text rendering with agg 2011-04-30 00:07:03 +00:00
Dane Springmeyer
157d52e38f add option to collect the total extent of all placement bboxs to enable passing along to metawriters - modified patch from kevin.kreaiser - closes #755 2011-04-30 00:06:27 +00:00
Dane Springmeyer
ab94fd43d8 add test for grid generation, and make sure point_datasource feature id starts at 1 (as datasources should) 2011-04-29 19:25:00 +00:00
Dane Springmeyer
e9e88e0481 remove uneeded includes 2011-04-29 17:40:15 +00:00
Dane Springmeyer
b072de4769 create layer descriptor when memory_datasource is created - TODO - gather attribute descriptors as features are added 2011-04-28 17:36:36 +00:00
Dane Springmeyer
31eea84d85 get iterator type right after r2843 2011-04-27 21:06:07 +00:00
Hermann Kraus
6650f999b9 char is to short for unicode chars. Replace it with unsigned int. Should fix #746. 2011-04-27 20:28:53 +00:00
Dane Springmeyer
5eea164b5a add grid_renderer backend 2011-04-26 21:44:52 +00:00
Dane Springmeyer
9da2d701a5 further template the svg_renderer based on pixfmt 2011-04-26 17:38:18 +00:00
Dane Springmeyer
7d394f3d09 load_map: report and check transform in all cases 2011-04-26 17:33:41 +00:00
Dane Springmeyer
5bbc89674e update comments 2011-04-19 00:20:04 +00:00
Dane Springmeyer
f8b3a4b946 add serialization of all markers_symbolizer attributes 2011-04-18 01:17:57 +00:00
Dane Springmeyer
7d08f76e50 add missing 'base' parameter to parse_shield_symbolizer and correct spelling of 'filter-factor' for parse_raster_symbolizer - closes #752 2011-04-18 01:11:38 +00:00
Dane Springmeyer
e00702cd79 touchup error message if zoom_all() fails 2011-04-15 22:46:53 +00:00
Dane Springmeyer
e79e7a1413 box2d: when copying actually copy exactly rather than using init to enforce validity - closes #749 2011-04-14 19:26:49 +00:00
Dane Springmeyer
7570cb5d73 load and save the new map 'maximum-extent' attribute 2011-04-14 02:32:51 +00:00
Dane Springmeyer
8998296f7b add 'maximum-extent' attribute to map and use this, if set, in place of calculated layer extents in zoom_all() 2011-04-14 02:20:33 +00:00
Dane Springmeyer
ac3488efb6 fix return from proj_transform when coordinates cannot be reprojected 2011-04-13 21:03:15 +00:00
Dane Springmeyer
9b1080e72e don't warn if mmap's file is missing (shapefile does not have an index) 2011-04-13 20:09:52 +00:00
Dane Springmeyer
383d8a3f15 add proj_transform forward/backward box2d implementation 2011-04-13 19:40:44 +00:00
Dane Springmeyer
903d1b49ef add a clip method to mapnik::box2d 2011-04-13 19:19:23 +00:00
Artem Pavlenko
7191d56a16 + throw image_reader_exception if we can't read tiff file
+ catch image_reader_exceptions in raster.input
+ re-throw in bind()
2011-04-11 21:17:10 +00:00
Artem Pavlenko
0e0b7a578c + implement memory mapping using boost::interprocess
+ cache mapped memory regions for re-use
2011-04-06 13:02:31 +00:00
Dane Springmeyer
2699ba42d0 avoid unused parameter compiler warnings 2011-04-04 04:35:28 +00:00
Dane Springmeyer
33f6cbf13d jpeg reader: make to sure call jpeg_finish_decompress if scanlines have been read 2011-04-04 04:03:03 +00:00
Dane Springmeyer
2d1e2ef998 add valid() method to box2d, and comment subtraction override as it does not have any function currently 2011-04-04 03:50:09 +00:00
Dane Springmeyer
27cc2f0dc5 catch errors in build time pkg-config parsing - closes #738 2011-04-02 03:11:42 +00:00
Dane Springmeyer
8f4386b7b2 use dynamically allocated, scoped array instead of variable-size array, which ISO C++ forbids 2011-04-02 03:07:45 +00:00
Dane Springmeyer
470f48beab avoid compiler warning of 'cast between pointer-to-function and pointer-to-object is an extension' with clang/gcc 2011-04-02 00:43:20 +00:00
Dane Springmeyer
d0e98eb3f1 handle return of fread 2011-04-01 23:54:58 +00:00
Dane Springmeyer
c1a6a54060 remove tabs 2011-04-01 20:47:26 +00:00
Dane Springmeyer
b65c932ac0 avoid -pedantic warnings 2011-04-01 07:20:41 +00:00
Dane Springmeyer
84ea9e6101 avoid clang++ -pedantic compiler warnings 2011-04-01 06:24:57 +00:00
Dane Springmeyer
eafac7fc7b comment out currently unused agg renderer headers 2011-04-01 06:14:55 +00:00
Dane Springmeyer
14068cad23 move segment y_order sort to header that can be used by each renderer 2011-03-22 00:02:50 +00:00
Artem Pavlenko
ec4ef1bb34 + add missing files from 735_metawriter_inmem.patch 2011-03-16 16:50:02 +00:00
Artem Pavlenko
e580078d26 + apply MetaWriter patch from zerebubuth
( see #735 for details )
2011-03-16 13:32:04 +00:00
Artem Pavlenko
b543d7f1f4 + add optional length parameter to allow
passing not-null terminated char strings
2011-03-16 13:31:56 +00:00
Robert Coup
8ace5b7e6b position shield symbolizer symbols centered (ie. with text), rather than top-left in cairo output. re #737 - thanks @jburgess for testing and @Ldp for the patch. 2011-03-15 22:25:37 +00:00
Dane Springmeyer
c93984f06f fix spelling 2011-03-15 20:50:30 +00:00
Hermann Kraus
f9040c6026 Show error message when invalid placement algorithm is selected. 2011-03-11 14:18:34 +00:00
Dane Springmeyer
4079fd7d08 make feature caching optional, and disabled by default (to avoid std::bad_alloc in low memory environments). Can be set as new layer property 'cache-features' - closes #657 2011-03-01 17:09:29 +00:00
Dane Springmeyer
efb19dea6c make the requirement of boost_regex unicode support optional by detecting if boost_regex was itself built with ICU support 2011-02-28 20:00:56 +00:00
Dane Springmeyer
2ea0340e2d avoid unintialized variable warnings in g++ 2011-02-28 18:30:38 +00:00
Hermann Kraus
714f918332 Fix indentation. 2011-02-28 13:29:39 +00:00
Hermann Kraus
4af0696b9d Add support for multiple placements.
NOTE: In some places indention is not updated to keep this patch readable. This will be fixed in the next revision.
2011-02-28 13:17:46 +00:00
Dane Springmeyer
4206c46f58 revert unintended change 2011-02-25 21:02:33 +00:00
Dane Springmeyer
03ee4570be make sure to install svg and wkt include files - thanks kiorky for initial patch - closes #718 2011-02-25 21:00:05 +00:00
Dane Springmeyer
545960a340 fix point_placement enum checking 2011-02-24 18:05:07 +00:00
Artem Pavlenko
d5bcf8dccb + fix include paths
+ update src/SConscript
2011-02-24 15:54:59 +00:00
Artem Pavlenko
57db45095f + boost.spirit WKT parser using mapnik::geometry_type
as synthesized attribute.
2011-02-24 15:47:53 +00:00
Artem Pavlenko
93514d57a2 + add missing geometry types
+ correct geometry types in wkb reader
2011-02-24 15:47:36 +00:00
Dane Springmeyer
9d351be091 update cairo renderer to include text-transform 'captitalize' support 2011-02-21 20:46:07 +00:00
Dane Springmeyer
a317c5d051 add 'capitalize' option to text-transform - closes #715 2011-02-21 20:43:26 +00:00
Carlos López
83a7b4710e Fixed a bug that caused half of the vertexes to disappear from the SVG path.
+ mapnik::geometry_iterator was replaced by mapnik::svg::path_iterator
+ svg::path_output_grammar was simplified
+ the container for this grammar is now coord_transform2, instead of geometry
+ added typedef size_type to coord_transform2 and removed it from geometry
2011-02-14 03:40:25 +00:00
Dane Springmeyer
f348c489ad fix property names in load_map error response 2011-02-11 21:32:47 +00:00
Dane Springmeyer
a9cda83300 check XML attributes for markers_symbolizer 2011-02-09 07:51:52 +00:00
Dane Springmeyer
0d5d014474 *warning* breaking change: move to consisten use of dashes (see #644), and start validating property names by printing warning if they are not valid (closes #110) 2011-02-05 03:15:17 +00:00
Dane Springmeyer
154dc59c5a serialize all dashes, no underscores, as per #644 2011-02-05 03:11:09 +00:00
Dane Springmeyer
c5833a6db8 remove unmaintained autotools scripts 2011-02-04 22:22:16 +00:00
Artem Pavlenko
046d99f3be + remove debug printout 2011-02-02 15:09:54 +00:00
Dane Springmeyer
50532801f3 change min_distance and min_padding to minimum_distance and minimum_padding to match python and mimimum_version 2011-02-02 04:20:53 +00:00
Dane Springmeyer
c8b816e498 add missing serialization of marker width and height 2011-02-02 03:47:52 +00:00
Dane Springmeyer
3197bea9ee add missing serialization of max_char_angle_delta and label_position_tolerance 2011-02-02 03:42:15 +00:00
Dane Springmeyer
c52c91c98a serialize point_placement 2011-02-02 02:17:06 +00:00
Dane Springmeyer
fd2d9d7ff3 enable aliased lines using stroke-gamma for line_symbolizer - closes #689 2011-02-02 01:46:14 +00:00
Dane Springmeyer
7043c416fa enable if/else type behavior in rules using style level keyword to control whether all rules will be evaluated or just the first that matches - closes #706 - thanks to original patch from kkaefer 2011-02-01 22:55:50 +00:00
Dane Springmeyer
75649b8863 add 'interior' point placement option to point_symbolizer - closes #709 2011-02-01 08:16:32 +00:00
Dane Springmeyer
e803b1c2ec add 'interior' placement option to text_symbolizr - patch from Toby Collet - closes #709 2011-02-01 08:13:08 +00:00
Robert Coup
bea611a185 Fix positioning problem with scale() transforms for SVG symbols. Centering transform applied in the wrong order. Thanks to Toby Collett. 2011-01-31 09:56:31 +00:00
Dane Springmeyer
78ec8b1724 fix reading of height value for building_symbolizer - TODO: make expression (#704) 2011-01-28 20:46:49 +00:00
Dane Springmeyer
5bf6efafb0 apply patch from Craig de Stigter for better scaling methods using agg image filters - closes #656 2011-01-27 03:47:54 +00:00
Dane Springmeyer
57f15aa74e forward declare agg:trans_affine and mapnik::marker classes to allow compiling against libmapnik without agg headers - see #703 2011-01-26 09:19:00 +00:00
Dane Springmeyer
481aeb6c98 comment debug output 2011-01-26 09:17:01 +00:00
Robert Coup
386a4f5daf #654 - add support for linear and radial gradients in SVG symbols. Thanks to Toby Collett for the coding & Paul Wicks for funding. 2011-01-26 01:18:40 +00:00
Dane Springmeyer
a79018d0a0 make sure to check relative paths behavior up front, and handle background-image properly - closes #702 2011-01-25 20:47:56 +00:00
Carlos López
85bfb11c03 SVG renderer grammars working with iterator of geometry, but generating wrong path vertexes (all vertexes are output as 0s). 2011-01-23 23:10:05 +00:00
Marcin Rudowski
5a55d99f9a making TextSymbolizer label placement consistant with agg renderer to give more similar output 2011-01-23 22:45:28 +00:00
Carlos López
bdfaee32a6 SVG_RENDERER is compiling now, but it won't generate path data, only simple svg tags.
+ It is working with vertex_vector, instead of vertex_vector2.
+ The body of every function related to path generation was commented out so mapnik would compile with SVG_RENDERER=True.
+ TODO: Create an iterator for geometry.
2011-01-22 06:47:20 +00:00
Artem Pavlenko
98b7f62155 + remove template from mapnik::rule
+ rename globaly rule_type -> rule
 ( ticket #552 )
2011-01-13 21:35:01 +00:00
Dane Springmeyer
d54a767dd4 make sure to put cairo/cairomm ldflags into the linkflags for the libmapnik environment 2011-01-13 20:32:19 +00:00
Dane Springmeyer
e0a765429f if a directory is not passed to register_fonts, then assume it is a font file and try registering it 2011-01-11 00:15:57 +00:00
Dane Springmeyer
2fa027855a don't return reference to temporary, and intialize metawriter values 2011-01-10 23:04:34 +00:00
Artem Pavlenko
be458e7ac0 + add support for boost::filesystem v3
(http://www.boost.org/doc/libs/1_45_0/libs/filesystem/v3/doc/deprecated.html)
2011-01-04 15:22:49 +00:00
Dane Springmeyer
47232c265a formatting 2010-12-15 00:42:37 +00:00
Dane Springmeyer
ed22d073c3 fix serialization of missing shield symbolizer properties 2010-12-11 02:07:47 +00:00
Dane Springmeyer
7fc193729c warn or throw if svg transform fails 2010-12-11 01:10:45 +00:00
Dane Springmeyer
7955178468 respect alpha of symbolizer for LINE placement as well as POINT and VERTEX placement 2010-12-10 22:31:57 +00:00
Robert Coup
1acc54f1fb TextSymbolizer: make '\n' trigger line break. fixes #584. Thanks bcrosby for porting to trunk 2010-12-09 08:48:46 +00:00
Dane Springmeyer
0eb3718934 actually parse label_position_tolerance from xml 2010-12-01 17:40:33 +00:00
Dane Springmeyer
baaf8041bb scons: linking libmapnik to boost_system is required solaris in 64 bit 2010-12-01 02:49:06 +00:00
Artem Pavlenko
6713df5937 + if avoid_edges=true check 'contains' using un-buffered extent. 2010-11-22 11:25:36 +00:00
Dane Springmeyer
b71c75bdeb clang++ caught bug - we need to first call lt_dlinit. Also add better error output based on returns from dladvise functions and simplify compile flag 2010-11-19 23:02:58 +00:00
Lucio Asnaghi
ba034abb1f + support of WKB geometry collection 2010-11-18 21:52:20 +00:00
Lucio Asnaghi
23e1904dca + fixed bad errors when parsing wkb 2010-11-18 20:33:45 +00:00
Dane Springmeyer
0b1d68f1f6 if libtool >=2.x.x is available, utilize the ability to set dlopen flags, so that plugins can be registered on linux without direct linking or modifying dlopen flags at runtime (like we currently do in python bindings) 2010-11-17 19:45:51 +00:00
Lucio Asnaghi
86a248d443 - leverage building extent (box2d) from string: multiple usage in datasources 2010-11-14 14:38:43 +00:00
Artem Pavlenko
d5f0a497a8 + auto detect paths orientation
+ not need to set clip box on rasterizer it's
  already set (fixes gap when label is overlapping border)
2010-11-10 14:40:05 +00:00
Dane Springmeyer
4f9dce9a0c only zoom to active layers 2010-11-08 18:57:30 +00:00
Dane Springmeyer
209b0697dc upgrade a hello world plugin and cairo renderer to fully use new geometry_type 2010-11-03 16:26:30 +00:00
Artem Pavlenko
ab101401cd + simplify geometry implementation
+ removed multiple geometry typedefs
+ use geometry_type
+ revert to storing vertices in vector_vertex
  (previous implementation using std::vector was
   fragmenting heap causing performance issues with large geometries)
+ FIXME: hit_test is broken!
2010-11-03 13:19:15 +00:00
Artem Pavlenko
0361061053 + fix text_minimum_padding.diff (#547) patch 2010-11-03 13:19:04 +00:00
Artem Pavlenko
0823b83900 + apply Nino Walker's patch text_minimum_padding.diff #547
TODO:  consider simplifying text symbolizer options
2010-11-03 13:18:56 +00:00
Dane Springmeyer
9281e6dcd8 avoid compiler warnings 2010-10-24 06:44:48 +00:00
Robert Coup
1dce437120 #622 add optional late-binding of datasources 2010-10-24 06:34:18 +00:00
Dane Springmeyer
aef676c090 add changes missed in r2287 2010-10-15 02:16:37 +00:00
Dane Springmeyer
3011f53205 add support to PointSymbolizer for 'ignore_placement' - #564 2010-10-15 02:15:40 +00:00
Dane Springmeyer
5d13869da1 if only width or height are supplied for a marker, make a circle - ellipses can be drawn by different width/height values 2010-10-15 00:14:18 +00:00
Dane Springmeyer
c8d5280b00 only render stroke on markers if it actually has a width 2010-10-15 00:12:51 +00:00
Dane Springmeyer
ca5d44032e explicitly set the runpath to libmapnik for the python bindings - in combination with ability to set 'CUSTOM_LDFLAGS' this closes #354 2010-10-12 04:40:00 +00:00
Dane Springmeyer
688b1f2299 add an 'extra_attributes' property to the map to store mapnik::parameters that don't make sense as full attributes but need to be carried through from load_map() to save_map() for applications that use mapnik to serialize to xml such as Cascadenik and Quantumnik (currently useful storage for 'minimum_version' and 'font_directory') 2010-10-07 19:34:36 +00:00
Dane Springmeyer
2fc2b4c443 add 'font_directory' attribute to map to allow for regstration of fonts within - in combination with r2025 this closes #168 2010-10-07 01:49:07 +00:00
Dane Springmeyer
806971e56d formatting 2010-10-05 20:13:03 +00:00
Artem Pavlenko
2f84e31e09 + revert using shield displacement in placement_finder
+ correct shield placement logic
   (TODO: ensure scale_factor works correctly)
2010-10-05 11:41:07 +00:00
Alberto Valverde
9c79d52ca0 Modified cairo_pattern in order to let cairo handle ownership of the image
buffer. This solves the issue mentioned in [2254] properly as it wasn't solved
properly before.
The bug is uncovered in cairo 1.10.0 and caused that images added to pdf
surfaces did not appear at all. My guess is that newest cairo reads the
pattern surface lazily when "trasnfering" it to the target surface and by the
time it does it the cairo_pattern which owns the buffer has already been
destroyed.
2010-10-01 11:22:39 +00:00
Alberto Valverde
215c223f68 Fixing issue when painting images into cairo PDFSurfaces which appears when using cairo 1.10.0. The context's surface needs to be marked as dirty after painting or else images won't be flushed. Earlier versions of cairo weren't as strict abouth this. Thanks to Company @ #cairo for helping out 2010-09-30 15:26:38 +00:00
Artem Pavlenko
4dbafdcec0 + apply scale_factor to shield/text displacement
+ fix recentering logic
2010-09-30 11:40:24 +00:00
Dane Springmeyer
49e6fa4480 fixup compile of cairo rendering backend after r2248 2010-09-28 18:27:42 +00:00
Artem Pavlenko
69221d1438 + apply scale_factor to spacing and minimum_distance
in placement_finder
2010-09-27 10:36:53 +00:00
Artem Pavlenko
8163be1cc2 + align text to pixel dim for svg shields 2010-09-27 10:07:21 +00:00
Artem Pavlenko
bbc797aeff + pass scale_factor to text placement 2010-09-27 09:58:30 +00:00
Artem Pavlenko
0727df6319 + recentre svg symbol before applying user transform 2010-09-27 09:58:21 +00:00
Artem Pavlenko
77da818cd9 + recentre SVG symbols before rendering
(todo: maybe better recentre SVGs at loading time)
2010-09-25 12:12:59 +00:00
Dane Springmeyer
5c424d2e7c add impl for grayscale_to_alpha (e.g. devseed world glass effect) - #609 2010-09-24 17:08:12 +00:00
Dane Springmeyer
0a300c8be7 impl of alpha setting in C++ core - should work now via python - #609 2010-09-24 16:12:23 +00:00
Dane Springmeyer
b3810a5f6a stub in new alpha manipulation functions for mapnik image - #609 2010-09-24 15:37:19 +00:00
Tom Hughes
05ab656b57 The upcoming 4.8.0 release of PROJ.4 is supposed to be threadsafe, so
lets believe them and not use any locks if we are building against
version 4.8.0 or later.

Instead we use the new proj_ctx_alloc routine to create a context and
pass that when initialising the projection structure.
2010-09-24 15:26:50 +00:00
Artem Pavlenko
8b92943608 + max_char_angle default to 25 degrees 2010-09-24 12:55:14 +00:00
Artem Pavlenko
86f4027d9d + store max_char_angle in radians
+ default to 25.0 degrees
2010-09-24 12:55:08 +00:00
Artem Pavlenko
71bfe37601 + align text placement to pixel boundary 2010-09-24 12:55:03 +00:00
Dane Springmeyer
c35310445a rename text_convert to text_transform to match css naming convention (also matching enums to css) 2010-09-18 19:10:18 +00:00
Dane Springmeyer
523b09701e Add the ability to pass custom CXXFLAGS and LDFLAGS that will be prioritized above other compiler and linker flags 2010-09-18 18:02:15 +00:00
Dane Springmeyer
e22c187e95 expose an indexing operator on box2d to allow for easy pythonic access to bounds parts 2010-09-16 14:41:29 +00:00
Artem Pavlenko
46f9a7188a + don't compensate dx/dy 2010-09-10 13:49:21 +00:00
Artem Pavlenko
acd05cb5cd + align text and shields to pixels 2010-09-10 13:15:34 +00:00
Artem Pavlenko
14971ed88c + initialise displacement_ with shield_displacement 2010-09-10 13:15:25 +00:00
Artem Pavlenko
56bca0d194 + re-use placement for subsequent points 2010-09-10 13:15:06 +00:00
Dane Springmeyer
df42fcde56 locking is required around pj_init_plus (partial revert of 2063) as it appears pj_init_plus will fail under high concurrent load even with proj 4.7.0 (only seen when reprojecting data) and will likely require use of a context (available in next release) if we wish to remove locks 2010-08-27 22:05:15 +00:00
Dane Springmeyer
9674171eb4 fixes for building on solaris and opensolaris, in addition to automatic running of ldconfig (will benefit builds on linux and fail silently otherwise) 2010-08-26 01:21:47 +00:00
Dane Springmeyer
22fc14ef05 + ability to pass coord2d to box2d::re_center in core and python 2010-08-19 21:35:27 +00:00
Dane Springmeyer
b307013ba2 add additional support for dynamically drawing ellipses in the markers_symbolizer, now supporting both line/point placement, metawriters for point placement, and width/height/stroke attributes - TODO - reflect in python bindings, buggy matrix transform for ellipses 2010-08-19 17:33:01 +00:00
Dane Springmeyer
1fcb0eebec serialize stroke separately from line_symbolizer, setting up for other symbolizers to share stroke attributes 2010-08-19 15:45:53 +00:00
Dane Springmeyer
b5f36154fc parse stroke properties separately from parsing a line symbolizer - setting up for being able to easily add strokes to other symbolizers 2010-08-19 12:20:30 +00:00
Dane Springmeyer
a7e9cc7e87 make output of empty json (if no features are hit) on by default, and rename parameter from 'only-nonempty' to 'output-empty' 2010-08-19 05:50:08 +00:00
Hermann Kraus
d3bb11456f Last Summer of Code changes: Support metawriter in upgrade_map_xml.py, fix attribute collector. 2010-08-16 19:14:21 +00:00
Hermann Kraus
55d9bf3290 Add glyph dimension caching and move functions from .hpp to .cpp 2010-08-13 18:41:54 +00:00
Hermann Kraus
b6f839b0f1 Calculate exact bounding boxes for GlyphSymbolizer. 2010-08-13 00:51:58 +00:00
Hermann Kraus
7fea0f7a6c Metawriter support for LineSymbolizer and LinePatternSymbolizer 2010-08-12 21:39:29 +00:00
Hermann Kraus
fb4baa4fcf Metawriter support for LineSymbolizer and LinePatternSymbolizer 2010-08-12 19:12:15 +00:00
Hermann Kraus
4cb09a8aca Fix small bugs. 2010-08-12 16:58:37 +00:00
Marcin Rudowski
bd8f189bd1 fix raster blending, ported r2137, fixing #589 2010-08-12 06:59:35 +00:00
Hermann Kraus
24fb874c7d Add metawriter support to save_map.cpp 2010-08-12 00:11:01 +00:00
Hermann Kraus
7dea58b625 Metawriter for Cairo. 2010-08-11 11:45:56 +00:00
Hermann Kraus
5867aadb66 Metawriter support for ShieldSymbolizer. 2010-08-11 03:25:15 +00:00
Hermann Kraus
a88ab24a72 Handle straight lines specially.
Add comment about coordinate systems.
2010-08-11 02:26:14 +00:00
Dane Springmeyer
0637d59b5c make SVG processor dependent (for now) on SVG_RENDERER scons option 2010-08-10 23:46:11 +00:00
Dane Springmeyer
6cce96dd06 upgrade default projection of epsg:4326 to match exactly what proj4 stores in /usr/local/share/epsg for 4326 (aka WGS84) 2010-08-10 18:18:31 +00:00
Hermann Kraus
7c5d0336c9 Small fixes + improvements. 2010-08-10 15:31:14 +00:00
Hermann Kraus
990df317fd "size" is not an optional GlyphSymbolizer attribute. 2010-08-10 14:46:39 +00:00
Hermann Kraus
de5d191a02 Metawriter support for GlyphSymbolizer. 2010-08-10 12:44:29 +00:00
Hermann Kraus
4dc2a466f8 Add symbolizer_base constructor to all symbolizers. 2010-08-10 12:43:21 +00:00
Hermann Kraus
ada706844a Remove unused function. 2010-08-10 12:20:02 +00:00
Hermann Kraus
30470bd52b Metawriter support for TextSymbolizer. 2010-08-10 12:19:19 +00:00
Hermann Kraus
85cd4b67c3 Get full fontsize information. 2010-08-10 12:05:38 +00:00
Hermann Kraus
9857583064 Parse metawriter attributes in all symbolizers. 2010-08-10 12:03:45 +00:00
Carlos López
fda7f66204 Added missing files from last commit. 2010-08-10 08:25:09 +00:00
Carlos López
e390715c58 Added support for processing multiple symbolizers to svg renderer. 2010-08-10 08:23:02 +00:00
Dane Springmeyer
6da5983e94 add xinclude support for libxml2 based parser - thanks oldtopos - closes #567 2010-08-10 06:01:16 +00:00
Hermann Kraus
0fdf3a2463 Pass parameter as const&. 2010-08-07 20:03:05 +00:00
Hermann Kraus
fb7913619a Bug fix: Don't warn about undefined metawriter when no metawriter is assigned to a symbolizer. 2010-08-07 20:00:43 +00:00
Dane Springmeyer
ca2aec8463 remove unneeded mutex include 2010-08-07 17:54:45 +00:00
Artem Pavlenko
f9b9c14500 pass parameters by const ref 2010-08-05 11:56:11 +00:00
Hermann Kraus
5725c694c6 Add "only-nonempty" to XML config. 2010-08-02 12:37:15 +00:00
Hermann Kraus
035e99d2f0 Only initialize proj_transform once in metawriter_json_stream. 2010-08-02 12:14:27 +00:00
Hermann Kraus
03718169b1 Only write non-empty tiles. 2010-08-02 01:35:18 +00:00
Hermann Kraus
75dcf67c92 Add some helper functions. 2010-08-02 00:37:15 +00:00
Hermann Kraus
0ae110015b Metawriter: Only write features that are actually rendered. 2010-08-01 15:07:50 +00:00
Hermann Kraus
8f8903baa5 Bugfix + better performance. 2010-07-31 10:20:56 +00:00
Carlos López
eec4864f41 SVG renderer now outputs path tags for polygons, with a fixed stroke color and size. 2010-07-30 22:15:50 +00:00
Carlos López
9af87ba8db SVG generator outputs path vertices in user coordinates. 2010-07-30 18:40:41 +00:00
Hermann Kraus
3791e95eda Some metawriter fixes. 2010-07-29 16:49:47 +00:00
Artem Pavlenko
170c36b14b + correct SVG_RENDERER flag usage in src/SConscript 2010-07-29 10:10:37 +00:00
Carlos López
6872d13968 Implemented svg_renderer::process_polygon_symbolier that uses the SVG path grammar, which outputs coords in map coords. 2010-07-28 06:50:25 +00:00
Carlos López
39a1038eb8 Added missing files: include/mapnik/svg/svg_generator.hpp and include/mapnik/svg/svg_generator_path_grammar.hpp. 2010-07-26 06:23:43 +00:00
Carlos López
f44333fa4e Added dummy grammar to generate SVG paths from geometries, as well as an SVG generator component. 2010-07-26 04:25:09 +00:00
Hermann Kraus
87fd78f313 Add support for dynamic filename in metawriters. 2010-07-25 22:41:18 +00:00
Hermann Kraus
7df4474f0b Add metawriter properties to Map object. 2010-07-25 21:05:30 +00:00
Hermann Kraus
20d5eb5698 Make "default-output" attribute optional. 2010-07-25 21:03:35 +00:00
Dane Springmeyer
dc99025348 make compile of svg renderer optional (but on by default) 2010-07-22 21:53:52 +00:00
Carlos López
b5b94a868c Changed template parameter type from stream to iterator and added a specialization for std::ostream_iterator. 2010-07-22 04:48:11 +00:00
Dane Springmeyer
f802d21865 speed optimizations by more careful use (or avoidance) of locking around projection code 2010-07-21 23:05:22 +00:00
Carlos López
f2a419bda7 Added template specialization svg_renderer<std::ofstream> to output SVG to file. Run tests/cpp_tests/svg_renderer_tests/file_output_test.cpp to generate one. 2010-07-21 07:43:13 +00:00
Carlos López
94e8ee3a9f Generation of output is now done through a stream iterator instead of the stream directly, which improves performance. Also made more compact generator for xml header, root element and bgcolor. 2010-07-21 03:34:46 +00:00
Dane Springmeyer
e021f27f96 explicitly convert doubles to int to avoid compiler warnings 2010-07-21 00:59:40 +00:00
Carlos López
07f329a538 Added generation of background color to svg_renderer. 2010-07-20 17:37:42 +00:00
Carlos López
bb44d76ee1 Added generation of SVG root element with width and height attributes. Also added test for testing the output generated by svg_renderer (combined_test.cpp). 2010-07-20 06:41:16 +00:00
Carlos López
789ff19824 Added generation of XML declaration and doctype definition to svg_renderer. 2010-07-20 01:35:01 +00:00
Carlos López
30e85c4d58 Added template parameter and data member to svg_renderer for holding the output stream. 2010-07-20 00:40:37 +00:00
Carlos López
eb7da9bcf5 Added the path of the svg_renderer's files to scons for compilation. There is no variable yet to disable their compilation. 2010-07-19 19:48:34 +00:00
Artem Pavlenko
91a109120b + align attribute names with W3C standards
rename 'bgcolor' to 'background-color'
+ update upgrade_map_xml.py
2010-07-19 12:01:34 +00:00
Artem Pavlenko
c943447509 + fix comment 2010-07-19 11:10:20 +00:00
Artem Pavlenko
8b8e247e62 + add support for background-image attribute
( background image is repeated both vertically
   and horizontally )
2010-07-19 11:10:03 +00:00
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
51a791eb77 scons: only attach uninstall actions if actually uninstalling - #311 2010-07-18 21:26:50 +00:00
Dane Springmeyer
267b48de49 add ability to uninstall all tracked scons targets using an 'uninstall' argument like 'scons uninstall' - closes #311 2010-07-18 20:39:05 +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
Carlos López
d273101adc Added empty svg_renderer class, with unimplemented methods. 2010-07-15 05:32:31 +00:00
Dane Springmeyer
08e96be4a1 scons: better handling of PYTHON_INCLUDES and HAVE_LIBXML2 2010-07-15 00:20:50 +00:00
Dane Springmeyer
d549cfe30a scons: only apply HAS_CAIRO & HAS_PYCAIRO flags to cairo related files 2010-07-14 22:47:34 +00:00
Artem Pavlenko
a2909f30bf + call arrange_orienrtations which fixes polygon orientations 2010-07-14 15:52:15 +00:00
Artem Pavlenko
5c2f51504a + call base class ctor 2010-07-14 14:46:26 +00:00
Artem Pavlenko
c7770ce6b1 Scaled text of shield symbolizer
(cherry-picked from mapnik-resolution branch)
2010-07-14 13:51:27 +00:00
Hermann Kraus
7e10a32503 Created a class for metawriter_properties. 2010-07-14 10:34:18 +00:00
Dane Springmeyer
4d477a47cd scons: conditionally add CXXFLAGS for headers needing Cairo support 2010-07-14 04:40:33 +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
03d6ef98c9 Undo accidential change. 2010-07-13 20:27:06 +00:00
Hermann Kraus
b218480835 Added default attributes for metawriter. 2010-07-13 20:24:44 +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
Dane Springmeyer
9889517497 only print info about metawriter when in debug mode 2010-07-06 05:49:48 +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
4fbcb989c1 + fixed to_expression_string converter for
<expr>.match(<pattern>) operator
2010-06-29 11:56:42 +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
Dane Springmeyer
83f91867bc remove raster_symbolizer and line_pattern_symbolizer from agg_renderer, moved to src/agg in r1929 2010-06-24 19:51:51 +00:00
Artem Pavlenko
36928706bb + apply scale_factor in building sym 2010-06-24 16:02:50 +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
Artem Pavlenko
392ae66941 + catch config_error in color::color(str) ctor 2010-06-21 11:06:42 +00:00
Artem Pavlenko
088f18263c + reverting r1734 (alberto) 2010-06-21 10:48:26 +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
74850a4839 break out polygon_pattern_symbolizer 2010-06-20 03:56:03 +00:00
Dane Springmeyer
43bc58f158 break out text symbolizer 2010-06-19 21:01:30 +00:00
Dane Springmeyer
1566b486fa break out agg-based glyph, line, and polygon symbolizers 2010-06-19 20:52:44 +00:00
Dane Springmeyer
fd17b14120 restore rendering of default point_symbolizer square, useful for debugging 2010-06-19 20:32:00 +00:00
Dane Springmeyer
36a8e19ad4 fixup more enums as done in r1893 2010-06-19 05:27:11 +00:00
Artem Pavlenko
e81b1abb8f + add implementation files 2010-06-18 15:39:57 +00:00
Artem Pavlenko
cf26db081a + refactor path expressions parser 2010-06-18 15:39:32 +00:00
Artem Pavlenko
b6089295e7 + put enumerartion macros into mapnik namespace
( clang++ emmits errors otherwise)
2010-06-18 15:39:07 +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
f0d579f742 + fixed ctor 2010-06-15 13:43:27 +00:00
Artem Pavlenko
e572b83d3a + fix copy ctor in symbolizer_with_image 2010-06-15 13:36:41 +00:00
Artem Pavlenko
b27357848d + set opacity on markers_symbolizer 2010-06-15 13:36:33 +00:00
Artem Pavlenko
9c47291f88 + use text-opacity in text_renderer 2010-06-15 12:28:13 +00:00
Artem Pavlenko
f7fe6dbf15 + apply opacity and text-opacity 2010-06-15 12:28:06 +00:00
Artem Pavlenko
d69dfe6656 + update load/save opacity/text-opacity 2010-06-15 12:27:58 +00:00
Artem Pavlenko
d4643e6d87 + add get/set opacity impl 2010-06-15 12:27:50 +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
d0b1e62c2d + removed deprecated direct access to io_ptr 2010-06-14 13:18:09 +00:00
Artem Pavlenko
d410377f10 + corrected <defs> skipping logic 2010-06-14 10:29:37 +00:00
Artem Pavlenko
b309bba36e + pass scale_factor to feature_style_processor 2010-06-14 10:29:29 +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
Artem Pavlenko
d272326d88 + skip <defs>...</defs> 2010-06-11 14:09:05 +00:00
Artem Pavlenko
7f03186cdf + don't recentre SVG markers 2010-06-10 16:35:01 +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
d39ed1d364 + apply scale_factor in agg_renderer 2010-06-10 14:12:28 +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
4dcef9d1a3 + disable setting paths orientation 2010-06-10 14:11:55 +00:00
Artem Pavlenko
9d98df89f1 + parse 'transform' parameter 2010-06-10 14:11:48 +00:00
Artem Pavlenko
48921a412d + refactor (TODO!) 2010-06-08 11:14:31 +00:00
Artem Pavlenko
4a986bc5ff + format 2010-06-08 11:14:23 +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
Dane Springmeyer
1b4f034ee5 add header needed for fopen on linux in jpeg_reader.cpp 2010-06-03 22:43:25 +00:00
Dane Springmeyer
6fc4d6f780 add support for reading jpeg images - closes #518 2010-06-03 21:24:58 +00:00
Dane Springmeyer
9804e7e90d scons: make libjpeg dependency optional (still required by default) 2010-06-03 19:50:27 +00:00
Dane Springmeyer
7d8bdb2f94 avoid compiler warning about uninittialized variable on osx 2010-06-03 18:46:13 +00:00
Artem Pavlenko
f67f6c4ec1 + add transformation matrix support 2010-06-03 12:36:00 +00:00
Artem Pavlenko
bc5730f006 + shield_symbolizer: support SVG images rendering
TODO: This is a first take, proper refactoring required!!!
2010-06-03 12:35:51 +00:00
Artem Pavlenko
5e43fefdba + don't qualify with mapnik:: namespace 2010-06-03 12:35:43 +00:00
Artem Pavlenko
d5a8f89d64 +load transform parameter in markers_symbolizer 2010-06-03 12:35:31 +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
816ebd2017 + remove mapnik:: (we're in mapnik namespace!) 2010-06-03 12:34:53 +00:00
Artem Pavlenko
ac468f05c2 + removed commented out lines 2010-06-03 12:34:45 +00:00
Artem Pavlenko
6cc6eac442 + move marker init out of geometry loop 2010-06-02 12:53:23 +00:00
Artem Pavlenko
246731874b + apply 'mapnik-format' to *.cpp *.hpp 2010-06-02 11:03:30 +00:00
Artem Pavlenko
9069df6492 + cleanup 2010-06-02 10:53:13 +00:00
Dane Springmeyer
218c75385d complete XML syntax change from CSSParameter to attributes (for BuildingSymbolizer and RasterSymbolizer) and update tests 2010-06-01 21:58:24 +00:00
Artem Pavlenko
484dce8943 + impl transform parameter (follow SVG spec) in point_symbolizer 2010-06-01 15:27:19 +00:00
Artem Pavlenko
b5362aa71a + tidy 2010-06-01 13:31:29 +00:00
Artem Pavlenko
9beb12b56b + split agg_renderer impl into different
translation units
+ add SVG support in point_symbolizer
2010-06-01 13:31:18 +00:00
Artem Pavlenko
12b74bc1cc + split agg_renderer implementation into diff
translation units
2010-06-01 13:31:08 +00:00
Dane Springmeyer
33145b18ae fix default initializations in markers_symbolizer 2010-05-30 16:09:39 +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
c9a4433666 make sure to return marker from cache, as noticed by Herm and mentioned in #553 2010-05-30 03:09:22 +00:00
Artem Pavlenko
f1986d1b85 + remove expat deps
+ correct includes
2010-05-28 16:34:58 +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
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
4584b05ff0 + small correction 2010-05-27 11:18:53 +00:00
Artem Pavlenko
e6e165f1e0 + use path-like geometries 2010-05-27 10:20:41 +00:00
Artem Pavlenko
cbf1356e4d + parse 'orientation' parameter 2010-05-27 10:20:10 +00:00
Artem Pavlenko
2085b3bc08 + apply orientation from text_symbolizer
+ fix building symbolizer
2010-05-27 10:20:03 +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
a688c36fdb serialize the experimental MarkersSymbolizer and avoid serializing defaults of GlyphSymbolizer unless requested 2010-04-15 21:42:28 +00:00
Dane Springmeyer
63ab05c112 ensure proper setting of allow_overlap and opacity when contructing a point_symbolizer without an image file 2010-04-15 06:09:21 +00:00
Artem Pavlenko
c20f16358c + save PolygobSymbolizer properties as attributes 2010-04-09 18:47:27 +00:00
Artem Pavlenko
23aac57a1f + use attributes instead of CssParameter 2010-04-09 18:47:19 +00:00
Artem Pavlenko
f776f8cd1e + add dash_offset 2010-04-09 18:46:41 +00:00
Artem Pavlenko
ca20f80ea8 + use attributes for LineSymbolizer properties 2010-04-09 18:46:33 +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
5890f17df3 + directly ctor default mapnik::color to avoid css color parsing 2010-03-24 18:02:10 +00:00
Artem Pavlenko
1a2b320252 + sanitize header inclusion a bit 2010-03-24 18:01:53 +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
2e04c5422a fixed serialization of expressions in glyph_symbolizer 2010-03-19 11:20:16 +00:00
Alberto Valverde
2d601f1bd7 fixed color's to_string method since alpha seems to no longer be parsed as a double. serializing a color to xml and deserializing it back did not work before 2010-03-19 11:20:00 +00:00
Alberto Valverde
aea5dd563a XML de/serialization for glyph_symbolizer. Some issues remain regarding unicode expr 2010-03-19 11:19:43 +00:00
Alberto Valverde
1e2ffb22b7 cairo rendering for the glyph_symbolizer. Small refactoring in cairo_context::add_text to pass the paramaters which were picked up from the text_symbolizer param (size, fill, halo_radius and halo_fill) explicitly. This allows the glyph_symbolizer to piggy back on that functionality without specilizing add_text() for the glyph_symbolizer (which would have involved heavy amounts of copy+paste or a more elaborate refactoring strategy. Please ping me if this was not a good idea 2010-03-19 09:33:57 +00:00
Alberto Valverde
e91c41e494 removed unneeded parenthesis 2010-03-19 09:33:41 +00:00
Alberto Valverde
f5409000f3 cosmetic changes and comments 2010-03-19 09:33:25 +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
e7bfba10fe + enanble installation of mapnik2 side by side with mapnik 2010-03-17 21:03:02 +00:00
Artem Pavlenko
83b20c3036 Revert "re factor expression grammar/parser stuff"
This reverts commit c58b8c4f71813a2490cf135573009c92be1a90c4.
2010-03-15 21:08:56 +00:00
Artem Pavlenko
0f8deb5e73 re factor expression grammar/parser stuff 2010-03-15 21:08:46 +00:00
Dane Springmeyer
d7256295ae port r1680/r1683/r1690 from 0.7.1-dev branch to trunk 2010-03-12 18:23:06 +00:00
Alberto Valverde
e9748abc5f xml de/serialization support for RasterColorizer 2010-03-12 14:49:50 +00:00
Alberto Valverde
807881c47a XML deserialization support for a raster_symbolizer with a colorizer 2010-03-12 14:49:34 +00:00
Alberto Valverde
2f1d60b666 pre-eliminary raster coloring support 2010-03-12 13:34:13 +00:00
Dane Springmeyer
6b76b3b9e8 properly serialize the map_buffer when saving map 2010-03-11 23:21:22 +00:00
Dane Springmeyer
3a44dd3258 + use rint(v) instead of int(round(v)) + add rint implementation - msvc hasn't got one + minor cleanups 2010-03-11 23:19:12 +00:00
Artem Pavlenko
c3a0b1a72f + revert to a024c947499994e1e8aaaff2b8ea73a8eec489dd 2010-03-08 11:55:15 +00:00
Dane Springmeyer
b8511eca65 restore default behavior of PointSymbolizer when used without an image, by defaulting to 4x4 black pixel - TODO - expose colors, shapes, and size for this in the future 2010-03-03 03:26:12 +00:00
Dane Springmeyer
b540dab73b apply slighly modified (env->box2d) mapnik-trunk.mr.raster-position2.diff from mar_rud to close #475 2010-03-03 03:23:53 +00:00
Dane Springmeyer
dd36810321 print warning if images are not found 2010-03-02 03:31:50 +00:00
Dane Springmeyer
07186fc6bb ensure shapeindex links against boost system if available (boost >=1.35) to avoid potential problems in indirect linking on linux (essentially directly dynamically linking like we previously only did on os x) - closes #517 2010-02-21 01:00:09 +00:00
Dane Springmeyer
e03c997024 assume byteorder arrives in native arch (from postgis), and therefore ensure byteswapping for wkb on big endian systems - closes #515 - TODO check breakage in other plugins as per #516 - thanks Brad Simpson for the report and fix 2010-02-19 07:50:47 +00:00
Dane Springmeyer
2cd0b55e88 enforce default gamma function - improves upon #428, closes #512 2010-02-09 17:28:17 +00:00
Dane Springmeyer
c3ea59c3c8 don't pass expression_ptr as const 2010-02-03 18:36:01 +00:00
Artem Pavlenko
05f5473924 + correct image bonding box calculation
+ check for zero sized images
2010-02-03 12:19:49 +00:00
Dane Springmeyer
ede29a1aff image 'type' is not longer needed or used so don't attempt to parse from XML 2010-02-01 21:32:09 +00:00
Dane Springmeyer
1af24f1eb8 Serialize FontSet instead of font_set as that is what the loader expects 2010-02-01 21:31:14 +00:00
Dane Springmeyer
c950e38a46 reenamble python access to TextSymbolizer 'name' expression 2010-01-30 03:08:03 +00:00
Dane Springmeyer
d599067a14 restore pretty printing of xml output (indent=4) now that we are using the new boost ptree which changed its defaults 2010-01-30 02:05:01 +00:00
Dane Springmeyer
aef4d350be repair serialization of XML filters and Text/ShieldSymbolizer 'name' attribute, which are how properly converted from expressions into strings 2010-01-30 00:47:06 +00:00
Dane Springmeyer
b1660b2152 fix formatting 2010-01-30 00:44:35 +00:00
Dane Springmeyer
da8ddb09ab gah, use the version header that actually exists for older versions of icu 2010-01-29 19:40:26 +00:00
Dane Springmeyer
05654f18bc quick fix to allow compiling without unicode regex support to enable builds against ICU <4.2 2010-01-29 19:22:15 +00:00
Dane Springmeyer
9b69f65ea9 add backwards compatibility support to the expressions parser so that the TextSymbolizer and ShieldSymbolizer 'name' parameter (and others in the future) syntax is understood as pre-0.8.0 syntax, while printing a deprecation warning - should allow older stylesheets to be used with Mapnik 0.8.0 - addresses #501 2010-01-26 23:03:42 +00:00
Dane Springmeyer
52d08e7d1a restore reading of paths relative to xml as default=true, print xml filename when errors are encountered, and remove unneeded check for pointsymbolizer file type which is now automatically handled in parse_path() 2010-01-26 22:54:03 +00:00