[gdal-dev] AREA_OR_POINT vs GDALMD_AREA_OR_POINT

Joaquim Luis jluis at ualg.pt
Thu May 29 14:48:04 PDT 2014


On 29-05-2014 22:08, Even Rouault wrote:
>
> >
>
> > Glad to not do, but than I'm left with nothing. If I do instead as 
> you say
>
> >
>
> > GDALSetMetadataItem(hDstDS, GDALMD_AREA_OR_POINT, "Point", NULL);
>
> >
>
> > which than equivalent to
>
> >
>
> > GDALSetMetadataItem(hDstDS, "AREA_OR_POINT", "Point", NULL);
>
> >
>
> > than, as I showed before and contrary to your python examples, the
>
> > GDALSetMetadataItem() is not working in our code.
>
> >
>
> > > On which dataset do you this : a GTiff dataset ? Opened in update 
> mode ?
>
> >
>
> > No, not update mode. It's dataset filled an empty MEM. See (lines #167
>
> > and after)
>
> >
>
> > 
> http://gmtrac.soest.hawaii.edu/projects/gmt/repository/entry/branches/5.2.0/
>
> > src/gmt_gdalwrite.c
>

> Well, I suppose that your local copy of the code use 
> GDALMD_ARE_OR_POINT unquoted...
>

as mentioned before, with and without.

> I've tried a simplified version of your code and it works for me. Do 
> you use a recent enough version of GDAL ?
>

Yes. A svn revision after 1.11.


> Note: for AREA_OR_POINT to be taken into account in GeoTiff, you need 
> to define both a geotransform and a SRS.
>

AHHHHHH. This changes the whole story. Some cases do not set a SRS. Is 
there any fall-back SRS that I could use when no info is available to 
create one?
Type, 'linear in unknown units'?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20140529/752922e1/attachment-0001.html>


More information about the gdal-dev mailing list