[gdal-dev] Reprojecting GeoTIFFs with Overviews?
Even Rouault
even.rouault at mines-paris.org
Thu Jan 10 11:47:05 PST 2013
Le jeudi 10 janvier 2013 19:03:33, Jason Greenlaw - NOAA Affiliate a écrit :
> Norman,
>
> Unfortunately that's not an option - In this case, my overviews are
> generated separately as individual .ovr files, e.g.:
>
> NGOFS_WL.tif
> NGOFS_WL.tif.ovr
> NGOFS_WL.tif.ovr.ovr
> NGOFS_WL.tif.ovr.ovr.ovr
> NGOFS_WL.tif.ovr.ovr.ovr.ovr
>
> I'm then stitching them together into a single image with gdal_translate
> -co COPY_SRC_OVERVIEWS=YES before attempting to reproject the result.
>
> Here's an example of what it looks like:
> http://jgreenlaw.org/gdal/ngofs-wl.png
>
> In each overview, the "streaklet" arrows actually need to be rendered at
> the proper resolution; I can't simply interpolate the original image.
>
> Perhaps I'm out of luck and need to reproject each of the .ovr files and
> the .tif files separately before combining them?
As indicated in the GeoTIFF driver documentation, COPY_SRC_OVERVIEWS only
works for CreateCopy() API, i.e. the one used by gdal_translate. gdalwarp used
the Create() API instead. That was the pedantic part of the answer.
Yes, if you don't want the overviews to be recomputed from the reprojected
image (the link to the image you provided doesn't really show why computed
overviews can't be used, anyway...) , the only option is to warp each source
overview level separately, and then recombine the result.
More information about the gdal-dev
mailing list