[Gdal-dev] missing FALSE_EASTING and Nodata value in my new driver

Frank Warmerdam fwarmerdam at gmail.com
Wed Feb 16 20:26:30 EST 2005


On Wed, 16 Feb 2005 18:06:34 +0000 (UTC), Gao, Peng <pgao at esri.com> wrote:
> (1) The projection string returned from my dataset contains a
>     false_easting value, and it is not
>     written to the output (JP2KAK). The following are two prj strings,
>     the first is what's returned
>     and the second is what's written (after reading it back):

Peng,

It turns out this was a bug in the GTIFFetchProjParms() function in 
libgeotiff.  It was not honouring ProjFalseOriginEastingGeoKey and
ProjFalseOriginNorthingGeoKey.  I have committed a fix for this
in libgeotiff, and updated the libgeotiff code within the GDAL source
tree.  

The problem also affects JP2KAK as it uses a degenerate GeoTIFF file
within the JP2 file to contain the coordinate system information. 

> (2) My data contains NoData, and the NoData value is 0. The
>     RasterBand::GetNoDataValue() never gets called.
> 
> What did I do wrong?

The JP2KAK driver has no support for preserving nodata values.  I am 
not aware of a standard way of doing this with JPEG2000.   I believe the
work we have previously discuss for persisting various kinds of metadata
will include support for nodata values in formats that do not naturally 
support them. 

So, you haven't done anything wrong, but at least for the time being the
capabilities of different drivers will vary.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent



More information about the Gdal-dev mailing list