[gdal-dev] geotiff projection not showing up
Trent Piepho
tpiepho at gmail.com
Sat Nov 9 15:14:42 PST 2013
On Sat, Nov 9, 2013 at 1:07 PM, Norman Goldstein <normvcr at telus.net> wrote:
> Things are better, now, but not quite there for me.
> Still not able to transform pixel/line to PCS space.
> (the listgeo dump is, below)
>
> I think the problem is that there is no definition of the
>
> ModelPixelScaleTag
>
> It seems that this tag, together with the ModelTiepointTag,
> is how an affine transformation is inferred. Or by directly
> setting
>
> ModelTransformationTag
>
> which I could do with GDALDataset's SetGeoTransform()
> method (for defining 2D affine transformations).
I've found that unless you call SetGeoTransform() and give an affine
transform, most apps, including listgeo and gdalsrsinfo, aren't
entirely happy with the georeferencing. GDAL has a function that
computes a transform from GCPs, but it needs to be part of the GDAL
code for the dataset driver. GDAL doesn't automatically do it when a
user of GDAL wants an affine transform from a dataset.
It seems like most code that tries to find corner coordinates and/or
the pixel size of a raster expects an affine transform plus a
projection. If there are a set of GCPs, then that code won't work.
The information may well be there, like your three GCP points, but the
GDAL user needs totally different code make use of it. It's the same
reason most of NOAA's nautical charts don't work with apps that use
GDAL or GDAL created GeoTIFFs. I've just started looking at the GDAL
code, but it doesn't seem like GDAL abstracts this enough to have
broad compatibility.
More information about the gdal-dev
mailing list