Le vendredi 09 novembre 2012 23:24:43, Robb Wright a écrit : > I just tried it on another machine on a number of .kaps - and some were > working and some were not - but they were different ones. Then I went > back to my first machine and I got the proper result, then ran it again > and got the error. Something must be dodgy with my libraries/how I have > it installed, but I can't imagine why it would work some times and not > others on the same file. > > If somebody else could try running it multiple times on the same file, > I'd be curious about their result. Below is a link to a set of 4. > Right now I'm getting errors on _1, _2 - but getting results for > _3,_4. Nutty. > http://www.charts.noaa.gov/RNCs/11308.zip > gdalsrsinfo.exe -o proj4 11308_1.KAP > gdalsrsinfo.exe -o proj4 11308_2.KAP > gdalsrsinfo.exe -o proj4 11308_3.KAP > gdalsrsinfo.exe -o proj4 11308_4.KAP
ok, I see what happens. In _3 and _4 cases, the BSB driver manages to compute a geotransform from the GCPs and then assigns a projection, in addition to the GCP projection. In the _1 and _2 cases, the BSB driver doesn't manage to compute the geotranform from the GCPs (which is a known issue sometimes with this driver, presumably because it has a too strict tolerance in the computation of the geotransform from the GCPs), so the projection is only reported by the GetGCPProjection() method, which the gdalsrsinfo never queries. In all cases, gdalinfo does show the projection and/or GCP projection. Perhaps gdalsrsinfo should also query the GCP projection if no regular projection is reported. _______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev