[gdal-dev] Problem with image overview creation in GTiff files
Frank Warmerdam
warmerdam at pobox.com
Fri Oct 17 14:40:48 EDT 2008
Ozy Sjahputera wrote:
> I am trying to create image overviews for a GTiff file using
> GDALDataset::BuildOverviews. I keep getting various errors such as:
>
> ERROR 1: TIFFSetField:VISUAL.tif: Cannot modify tag "Compression" while
> writing
...
> writing
> ERROR 1: TIFFSetField:VISUAL.tif: Cannot modify tag "TileLength" while
> writing
> ERROR 1: TIFFBuildOverviews:Can not write tiles to a stripped image
>
>
> Here is my code:
>
> int OverviewList[5] = { 2, 4, 8, 16, 32 };
> CPLErr overview_err = outDS->BuildOverviews( "AVERAGE_MAGPHASE", 5,
> OverviewList, 0, NULL, NULL, NULL );
>
>
> I have used BuildOverviews before on HFA images and they are fine. Any
> idea?
Ozy,
I'm surprised. I wonder if you might have opened your file in read-only
mode? Can you reproduce the problem with the gdaladdo commandline program?
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