[gdal-dev] VRT and overviews

Dmitry Baryshnikov polimax at mail.ru
Wed Apr 4 09:24:43 EDT 2012


04.04.2012 16:57, Oyvind Idland ???????:
> How do I get overviews to work with VRT datasets ?
>
> What I do is
>  - creating a .vrt with additional alpha band + nodata using 
> gdalbuildvrt (wrapping an existing TIFF)
>  - creating overviews using gdaladdo. I then get an external .ovr file.
>  - creating a new TIFF from the VRT
>
> First, it seems that the .vrt does not get updated, as there is no 
> <Overview> tags. I then tried to manually add <Overview> for each band,
> but the output TIFF does not have overviews in it.. just the original 
> bitmap and a mask for it.
>
> Example:
>
> gdalbuildvrt _r-32-2-4776-64728.vrt -overwrite -addalpha -srcnodata 0 
> -vrtnodata 0 r-32-2-4776-64728.tif
>
> gdaladdo _r-32-2-4776-64728.vrt 2 4 8 16 32 64
>
> gdal_translate -of GTiff -co COMPRESS=JPEG -co JPEG_QUALITY=80 -co 
> PHOTOMETRIC=YCBCR -b 1 -b 2 -b 3 -mask 4 -co COPY_SRC_OVERVIEWS=YES 
> --config GDAL_TIFF_INTERNAL_MASK YES _r-32-2-4776-64728.vrt 
> output\r-32-2-4776-64728.tif
>
>
> Also, I tried to add overviews embedded inside the source tiff 
> (wrapped in the same .vrt), but still no overviews in the output.
>
> Note, that what I'm really trying to do, is to create TIFF with JPEG 
> compression, and adding a mask that is not "contaminated" with jpeg 
> artifacts.
>
> What am I doing wrong ? :)
>
>
> -- oyvind
>
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
This is the bug and I'm working to fix it.
I think this bug are mentioned in such tickets 
http://trac.osgeo.org/gdal/ticket/2076 and 
http://trac.osgeo.org/gdal/ticket/3482

Regards,
     Dmitry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20120404/db6c7ed8/attachment.html


More information about the gdal-dev mailing list