Commit graph

831 commits

Author SHA1 Message Date
Hermann Kraus
924f3fb19c Raise Exception instead of returning None. 2012-09-26 14:52:49 -07:00
Dane Springmeyer
78790e6692 fix conflicts from cherry-picking 8cfb40a 2012-09-26 14:21:03 -07:00
Hermann Kraus
f27578d41c Add TextSymbolizer.name in python bindings.
Refs #1482.
2012-09-14 02:00:45 +02:00
Dane Springmeyer
c0539406d8 fix includes post bf3efbeab8 - refs #1435 2012-08-23 11:34:13 -07:00
Dane Springmeyer
ce03b3599b expose svg output for geometries - refs #1437 (TODO: support svg_multi_generator) 2012-08-22 19:13:37 -07:00
Dane Springmeyer
501d322c96 +reflect comp_op, smooth, and clip in python bindings for all relevant symbolizers - closes #1264 2012-08-21 18:05:43 -07:00
Dane Springmeyer
e8101a070a partially repair backward compatibility in python for 'marker-type' - refs #1427 and #1285 2012-08-21 16:36:15 -07:00
Dane Springmeyer
ab5ce64b16 python: add properties to mapnik.Stroke to match xml/svg spec - refs #1427 2012-08-21 15:59:31 -07:00
Dane Springmeyer
6a0df52b1c python: add wrap_character alias to wrap_char - refs #1427 2012-08-21 14:48:10 -07:00
Dane Springmeyer
d069ce7405 apply patch from @lightmare for fixing return of text_transform - closes #1420 2012-08-21 14:37:35 -07:00
Dane Springmeyer
0dec6c69ca +reflect miterlimit in python 2012-08-20 19:19:21 -07:00
Dane Springmeyer
72f967924e +reflect new opacity propert of polygon_pattern_symbolizer in python 2012-08-20 18:52:07 -07:00
Dane Springmeyer
6ca9196c98 remove unused header 2012-08-20 18:22:46 -07:00
Dane Springmeyer
3e4d579a5e +reflect background_image in python and add background_color to match XML 2012-08-20 18:18:36 -07:00
Dane Springmeyer
b76c8e5c64 +reflect building symbolizer in python 2012-08-20 18:17:00 -07:00
Dane Springmeyer
9273f861bc reflect all new style properties in python - refs #1264 2012-08-20 17:17:37 -07:00
Dane Springmeyer
8c8cf71d52 python: add 'status' property to match XML - refs #1418 2012-08-20 17:16:47 -07:00
Dane Springmeyer
55646ce236 fix group_by on layer to be std::string const& and reflect in python 2012-08-20 16:26:41 -07:00
Rich Wareham
0301294c84 python bindings: add wkt_features helper to PythonDatasource
The Python plugin datasource helper class already contained a helper for generating WKB features. This patch adds an
almost identical helper for WKT features. This is to facility Python data source who generate their features directly
using the text formatting support in Python.
2012-08-18 17:15:38 +01:00
artemp
f24641e802 + add envelope() method to mapnik.Path 2012-08-17 16:53:43 +01:00
artemp
258ea94d8d + add_geojson and from_geojson methods
+ add_wkb,from_wkb throw RuntimeError
+ cleanups
2012-08-17 12:48:41 +01:00
Dane Springmeyer
ad2250a4b5 back compatibility for raster-mode values using _ and shield-no-text 2012-08-16 19:20:29 -07:00
Dane Springmeyer
62e039d2c9 double grid encoding performance in python - closes #1315 2012-08-16 18:39:11 -07:00
Dane Springmeyer
58d848ae8e c++ style 2012-08-16 18:25:06 -07:00
Dane Springmeyer
25a1643d54 partial revert of e6e32fc and general cleanup to match node-mapnik grid api - refs #1325 and 1315 2012-08-16 17:51:36 -07:00
Dane Springmeyer
a986aedd05 remove 'info' and 'fatal' severities for logging to simplify framework - closes #1400 2012-08-16 15:52:32 -07:00
Dane Springmeyer
a3e27ed726 Merge branch 'master' of github.com:mapnik/mapnik 2012-08-16 12:29:27 -07:00
Dane Springmeyer
d850ee8b76 correct various old trac links to point to github - closes #1396 2012-08-16 12:27:58 -07:00
Dane Springmeyer
ecb72d6cbc scons: don't run parseconfig if uninstalling 2012-08-16 10:00:05 -07:00
artemp
8bba93d299 + don't pass std::string arg by value - use const& 2012-08-16 12:05:31 +01:00
artemp
e6e32fcb39 + applied patch from @lightmare - #1325 2012-08-16 11:00:07 +01:00
Dane Springmeyer
91b15c4cdf remove python pickling for map/style/rule/symbolizers/fontset/query - refs #1391 2012-08-15 13:55:36 -07:00
Dane Springmeyer
b8a0587c29 disable deepcopy in python bindings until this is more solid - refs #1390 2012-08-15 13:27:44 -07:00
Dane Springmeyer
6f5d6f65b1 include what you use 2012-08-15 10:24:56 -07:00
artemp
aecf0531f5 + remove metawriters for the upcoming 2.1 release 2012-08-15 09:47:03 +01:00
Dane Springmeyer
3d048c5f72 add ticket reference for workaround added in 60d843a7a8 2012-08-14 12:19:56 -07:00
Dane Springmeyer
339fd59293 +reflect line_symbolizer offset 2012-08-13 14:06:11 -07:00
artemp
7847af51e7 + fix __iter__ protocol 2012-08-08 16:15:54 +01:00
artemp
abd40edfd9 + add std::runtime_error to python translator 2012-08-08 12:11:30 +01:00
artemp
c2dca42a4f + use Py_RETURN_NONE
+ cleanup/simplify
2012-08-07 17:01:03 +01:00
artemp
7cfdfde247 + call Py_RETURN_NONE macro to properly handle returning Py_None
(http://docs.python.org/c-api/none.html) - thanks, @lightmare!
2012-08-07 15:43:40 +01:00
artemp
9da9ffadc1 + don't crash on empty paths 2012-08-07 14:47:28 +01:00
artemp
60d843a7a8 + temp fix : provide get_fill_opacity_impl to avoid
"No to_python (by-value) converter found for C++ type: float"
2012-08-07 11:37:24 +01:00
Artem Pavlenko
189322ef9f Merge pull request #1337 from rjw57/rjw57-python-plugin
Request for comments: python: a new plugin to use arbitrary Python as a data source
2012-08-06 05:09:29 -07:00
artemp
5541ea0271 + layer : minimum-extent and buffer-size
+ agg::process_xxx : remove ad-hoc query_extent modifiers
+ ctrans : simplify vertex skipping
2012-08-01 15:44:36 +01:00
Dane Springmeyer
a9f99848c2 expose boost::optional<mapnik::stroke> for markers_symbolizer (which works as oopposed to boost::optional<double> and boost::optional<float> which are broken 2012-07-31 18:40:53 -07:00
Dane Springmeyer
f60f40c939 Merge pull request #1157 from mapnik/stroke-as-reference
make stroke property on line_symbolizer a reference when accessed from python (not a copy)
2012-07-31 18:20:55 -07:00
Dane Springmeyer
16084ff335 support both interior placement and point for markers - helps prepare for #952 2012-07-31 18:13:50 -07:00
Rich Wareham
156a7590f4 python: a new plugin to use arbitrary Python as a data source
This plugin allows you to write data sources in the Python programming language.
This is useful if you want to rapidly prototype a plugin, perform some custom
manipulation on data or if you want to bind mapnik to a datasource which is most
conveniently accessed through Python.

The plugin may be used from the existing mapnik Python bindings or it can embed
the Python interpreter directly allowing it to be used from C++, XML or even
JavaScript.

Mapnik already has excellent Python bindings but they only directly support
calling *into* mapnik *from* Python. This forces mapnik and its input plugins to
be the lowest layer of the stack. The role of this plugin is to allow mapnik to
call *into* Python itself. This allows mapnik to sit as rendering middleware
between a custom Python frontend and a custom Python datasource. This increases
the utility of mapnik as a component in a larger system.

There already exists MemoryDatasource which can be used to dynamically create
geometry in Python. It suffers from the problem that it does not allow
generating only the geometry which is seen by a particular query. Similarly the
entire geometry must exist in memory before rendering can progress. By using a
custom iterator object or by using generator expressions this plugin allows
geometry to be created on demand and to be destroyed after use. This can have a
great impact on memory efficiency. Since geometry is generated on-demand as
rendering progresses there can be arbitrarily complex 'cleverness' optimising
the geometry generated for a particular query. Obvious examples of this would
be generating only geometry within the query bounding box and generating
geometry with an appropriate level of detail for the output resolution.
2012-07-31 17:05:27 +01:00
Dane Springmeyer
0d97b851fa markers: support opacity on bitmaps, and move to supporting both opacity and fill-opacity 2012-07-30 18:31:21 -07:00