Ok, thanks, good to know.<br><br>-- oyvind<br><br><div class="gmail_quote">On Wed, Apr 4, 2012 at 3:24 PM, Dmitry Baryshnikov <span dir="ltr"><<a href="mailto:polimax@mail.ru">polimax@mail.ru</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
04.04.2012 16:57, Oyvind Idland ÎÁÐÉÓÁÌ:
<blockquote type="cite"><div><div class="h5">How do I get overviews to work with VRT datasets ?<br>
<br>
What I do is<br>
š- creating a .vrt with additional alpha band + nodata using
gdalbuildvrt (wrapping an existing TIFF)<br>
š- creating overviews using gdaladdo. I then get an external .ovr
file.<br>
š- creating a new TIFF from the VRT<br>
<br>
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,<br>
but the output TIFF does not have overviews in it.. just the
original bitmap and a mask for it.<br>
<br>
Example:<br>
<br>
gdalbuildvrt _r-32-2-4776-64728.vrt -overwrite -addalpha
-srcnodata 0 -vrtnodata 0 r-32-2-4776-64728.tif<br>
<br>
gdaladdo _r-32-2-4776-64728.vrt 2 4 8 16 32 64<br>
<br>
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<br>
<br>
<br>
Also, I tried to add overviews embedded inside the source tiff
(wrapped in the same .vrt), but still no overviews in the output.<br>
<br>
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.<br>
<br>
What am I doing wrong ? :)<br>
<br>
<br>
-- oyvind<br>
<br>
<fieldset></fieldset>
<br>
</div></div><pre>_______________________________________________
gdal-dev mailing list
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a></pre>
</blockquote>
This is the bug and I'm working to fix it.<br>
I think this bug are mentioned in such tickets <a href="http://trac.osgeo.org/gdal/ticket/2076" target="_blank">http://trac.osgeo.org/gdal/ticket/2076</a>
and <a href="http://trac.osgeo.org/gdal/ticket/3482" target="_blank">http://trac.osgeo.org/gdal/ticket/3482</a><br>
<br>
Regards,<br>
ššš Dmitry<br>
</div>
<br>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br>