[gdal-dev] Compression artifacts

Jan Hartmann j.l.h.hartmann at uva.nl
Thu Dec 27 06:35:25 PST 2012


On 12/27/2012 03:11 PM, Even Rouault wrote:
> Le jeudi 27 décembre 2012 15:11:23, Jan Hartmann a écrit :
>> On 12/27/2012 02:41 PM, Even Rouault wrote:
>>> I've just pushed a fix since building overviews with "--config
>>> COMPRESS_OVERVIEW JPEG -- config PHOTOMETRIC_OVERVIEW
>>> YCBCR" when there's a .msk didn't work.
>>>
>>>> OK Even, thanks. This means that I should use gdal-svn?
>>> Not necessarily. I think you can workaround the issue by manually
>>> building the overview on the .msk file as a post-processing step :
>>>
>>> gdaladdo -ro --config COMPRESS_OVERVIEW DEFLATE small.tif.msk 2 4 8 16 32
>>> 64
>> Do you mean I should use DEFLATE instead of JPEG as compression for
>> overviews for the time being? What is the difference in compression ratio?
> Use DEFLATE only for the mask file (see small.tif.msk in the above command
> line), as it is a lossless compression, which is needed for a mask. JPEG is
> fine for the imagery itself
Sorry, I don't understand. Where does that small.tif.msk come from? 
Until now I had:
- the original raster (big.tif)
- the raster masked with nearblack (big_with_mask.tif)
- the compressed raster (gdal_translate -co...)
- the overviews built with gdaladdo

The mask is part of the raster file, isn't  it?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20121227/4f72fe48/attachment.html>


More information about the gdal-dev mailing list