@@ -36,7 +36,7 @@ Napi::Object Projection::Initialize(Napi::Env env, Napi::Object exports, napi_pr
36
36
* @throws {Error} the projection could not be initialized - it was not found
37
37
* in proj4's tables or the string was malformed
38
38
* @example
39
- * var wgs84 = new mapnik.Projection('+init= epsg:4326');
39
+ * var wgs84 = new mapnik.Projection('epsg:4326');
40
40
*/
41
41
42
42
Projection::Projection (Napi::CallbackInfo const & info)
@@ -87,7 +87,7 @@ Projection::Projection(Napi::CallbackInfo const& info)
87
87
* @param {Array<number>} position as [x, y] or extent as [minx,miny,maxx,maxy]
88
88
* @returns {Array<number>} projected coordinates
89
89
* @example
90
- * var merc = new mapnik.Projection('+init= epsg:3857');
90
+ * var merc = new mapnik.Projection('epsg:3857');
91
91
* var long_lat_coords = [-122.33517, 47.63752];
92
92
* var projected = merc.forward(long_lat_coords);
93
93
*/
@@ -315,7 +315,7 @@ Napi::Value ProjTransform::forward(Napi::CallbackInfo const& info)
315
315
{
316
316
std::ostringstream s;
317
317
s << " Failed to forward project "
318
- << x << " ," << y << " from " << proj_transform_->source (). params () << " to " << proj_transform_-> dest (). params ();
318
+ << x << " ," << y << " " << proj_transform_->definition ();
319
319
Napi::Error::New (env, s.str ().c_str ()).ThrowAsJavaScriptException ();
320
320
return env.Undefined ();
321
321
}
@@ -334,7 +334,7 @@ Napi::Value ProjTransform::forward(Napi::CallbackInfo const& info)
334
334
{
335
335
std::ostringstream s;
336
336
s << " Failed to forward project "
337
- << box << " from " << proj_transform_->source (). params () << " to " << proj_transform_-> dest (). params ();
337
+ << box << " " << proj_transform_->definition ();
338
338
Napi::Error::New (env, s.str ()).ThrowAsJavaScriptException ();
339
339
return env.Undefined ();
340
340
}
@@ -385,7 +385,7 @@ Napi::Value ProjTransform::backward(Napi::CallbackInfo const& info)
385
385
{
386
386
std::ostringstream s;
387
387
s << " Failed to back project "
388
- << x << " ," << y << " from " << proj_transform_->dest (). params () << " to: " << proj_transform_-> source (). params ();
388
+ << x << " ," << y << " " << proj_transform_->definition ();
389
389
Napi::Error::New (env, s.str ()).ThrowAsJavaScriptException ();
390
390
return env.Null ();
391
391
}
@@ -404,7 +404,7 @@ Napi::Value ProjTransform::backward(Napi::CallbackInfo const& info)
404
404
{
405
405
std::ostringstream s;
406
406
s << " Failed to back project "
407
- << box << " from " << proj_transform_->source (). params () << " to " << proj_transform_-> dest (). params ();
407
+ << box << " " << proj_transform_->definition ();
408
408
Napi::Error::New (env, s.str ()).ThrowAsJavaScriptException ();
409
409
return env.Null ();
410
410
}
0 commit comments