From bb284d0cfc1a4ab69ef93866f4e00680126589d2 Mon Sep 17 00:00:00 2001 From: Artem Pavlenko Date: Sat, 10 Jan 2009 17:57:59 +0000 Subject: [PATCH] + enable multiple python threads patch from jonb --- bindings/python/mapnik_python.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bindings/python/mapnik_python.cpp b/bindings/python/mapnik_python.cpp index 2b245a6a1..cb89c1481 100644 --- a/bindings/python/mapnik_python.cpp +++ b/bindings/python/mapnik_python.cpp @@ -73,14 +73,18 @@ void export_projection(); void render(const mapnik::Map& map,mapnik::Image32& image, unsigned offset_x = 0, unsigned offset_y = 0) { + Py_BEGIN_ALLOW_THREADS mapnik::agg_renderer ren(map,image,offset_x, offset_y); ren.apply(); + Py_END_ALLOW_THREADS } void render2(const mapnik::Map& map,mapnik::Image32& image) { + Py_BEGIN_ALLOW_THREADS mapnik::agg_renderer ren(map,image); ren.apply(); + Py_END_ALLOW_THREADS } #if defined(HAVE_CAIRO) && defined(HAVE_PYCAIRO)