Le mercredi 24 juillet 2013 15:43:11, David Strip a écrit :
> I had considered validate(), but decided against it for the reason you
> suggest - an initialized SRS might be in some weird format that fails
> validation. I've been using exportToWkt(), but was/am concerned that it
> might be possible to fail to export in odd-ball situations. Hence, my
> question about a direct check. Sounds like exportToWkt() is my best bet.

exportToWkt() cannot fail (except out-of-memory problem). (Valid) WKT 
representation and OSR model are completely bijective.

Another way of testing is OGRSpatialReference has been initialized is to test 
if poSRS->GetRoot() != NULL. (only available in the C++ API)

Even

-- 
Geospatial professional services
http://even.rouault.free.fr/services.html
_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to