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
This commit is contained in:
parent
12dd97a772
commit
df42fcde56
2 changed files with 11 additions and 7 deletions
|
@ -24,7 +24,7 @@ Mapnik Trunk
|
|||
|
||||
- Added xinclude (http://www.w3.org/TR/xinclude/) support to libxml2-based xml parser (oldtopos) (#567)
|
||||
|
||||
- Optimized rendering speeds by avoiding locking in the projection code (r2063)
|
||||
- Optimized rendering speeds by avoiding locking in the projection code (r2063) (r2713)
|
||||
|
||||
- Added support for setting global alignment of polygon pattern fills (#203)
|
||||
|
||||
|
@ -115,9 +115,9 @@ Mapnik 0.7.0 Release
|
|||
|
||||
- Shape Plugin: Fixed missing compiler flags that causes crashing on newer g++ versions (#436)
|
||||
|
||||
- PNG: Fixed problem with garbled/striped png256 output along sharpe edges(#416,#445,#447,#202)
|
||||
- PNG: Fixed problem with garbled/striped png256 output along sharp edges(#416,#445,#447,#202)
|
||||
|
||||
- PNG: Added support for semitransparency in png256 output (#477,#202)
|
||||
- PNG: Added support for semi-transparency in png256 output (#477,#202)
|
||||
|
||||
- PolygonSymbolizer: Added 'gamma' attribute to allow for dilation of polygon edges - a solution
|
||||
to gap artifacts or "ghost lines" between adjacent polygons and allows for slight sharpening of
|
||||
|
|
|
@ -124,10 +124,14 @@ projection::~projection()
|
|||
|
||||
void projection::init()
|
||||
{
|
||||
// http://trac.osgeo.org/proj/wiki/ThreadSafety
|
||||
#if PJ_VERSION < 470 && MAPNIK_THREADSAFE
|
||||
// Based on http://trac.osgeo.org/proj/wiki/ThreadSafety
|
||||
// you could think pj_init was threadsafe in version 4.7.0
|
||||
// but its certainly not, and must only be in >= 4.7 with
|
||||
// usage of projCtx per thread
|
||||
//#if PJ_VERSION < 470 && MAPNIK_THREADSAFE
|
||||
// mutex::scoped_lock lock(mutex_);
|
||||
//#endif
|
||||
mutex::scoped_lock lock(mutex_);
|
||||
#endif
|
||||
proj_=pj_init_plus(params_.c_str());
|
||||
if (!proj_) throw proj_init_error(params_);
|
||||
is_geographic_ = pj_is_latlong(proj_) ? true : false;
|
||||
|
|
Loading…
Reference in a new issue