[gdal-dev] Reading shapefile PRJ failing
Jan Heckman
jan.heckman at gmail.com
Sat Jul 12 11:23:45 PDT 2014
afaik PRJ files should be pure (ascii)text. You could refer to getting rid
of BOM
<http://stackoverflow.com/questions/204765/elegant-way-to-search-for-utf-8-files-with-bom>
to
clean them out.
Do not know an additional parameter for the file opener/reader.
Jan
On Sat, Jul 12, 2014 at 6:45 PM, mccorb <mccorb at cox.net> wrote:
> So I have tracked this down to the fact that the PRJ files that I have been
> given to use have a BOM of 0xEF 0xBB 0xBF for the first three bytes of the
> file.
>
> When I use the shapefiles that have these byte order markers the Layer
> class
> method getSpatialRef() (java JNI bindings) returns null. I am guessing that
> the PRJ file is being opened in binary mode instead of text mode possibly?
>
> Regardless, is there any setting I can make to coerce the file
> opener/reader
> into ignoring the BOM when grabbing the WKT from the PRJ file?
>
> thanks
>
>
>
> --
> View this message in context:
> http://osgeo-org.1560.x6.nabble.com/Reading-shapefile-PRJ-failing-tp5150778.html
> Sent from the GDAL - Dev mailing list archive at Nabble.com.
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20140712/f1714eff/attachment.html>
More information about the gdal-dev
mailing list