[gdal-dev] GDAL 1.11 vs 2.1 and JPEG2000?
Even Rouault
even.rouault at spatialys.com
Wed Jan 6 02:25:23 PST 2016
Le mardi 05 janvier 2016 18:51:03, Jim Lacy a écrit :
> Can anyone with knowledge of the JP2OpenJPEG driver confirm or deny the
> following observation?
>
> I've been generating jpeg2000's in both GDAL 1.11.2 and GDAL 2.1. With all
> settings the same, I've noticed the visual quality of the images generated
> in GDAL 2.1 are noticeably "better." (a subjective term, yes)
>
> To my eyes, in 1.11.2, -co "QUALITY=20" yields results visually comparable
> to roughly -co "QUALITY=12" in GDAL 2.1. Win32 platform, binaries from
> gisinternals.com.
>
> Are there significant improvements in the 2.1 driver that would explain my
> observation?
Jim,
Checking the NEWS, I believe this might be related to this improvement I did
in GDAL 2.0
* add YCC creation option to do RGB->YCC MCT, and turn it ON by default
(#5634)
And a quick test confirms it with a BMNG 21600x21600 3 bands :
$ gdal_tanslate in.tif out1.jp2 -of jp2openjpeg
$ gdal_tanslate in.tif out2.jp2 -of jp2openjpeg -co YCC=OFF
$ ll out1.jp2 out2.jp2
-rw-r--r-- 1 even even 111977681 2016-01-06 11:07 out1.jp2
-rw-r--r-- 1 even even 151981743 2016-01-06 11:08 out2.jp2
RGB->YCC MCT conversion is a step that occurs before other processings, which
tends to decrease the size of the resulting file, all other things equal. This
transform is not completely lossless when using the default lossy compression
(there's a lossless version that is used when using -co QUALITY=100 -co
REVERSIBLE=YES), but the differences in pixel values tend to be very small
between YCC=ON/OFF.
Even
--
Spatialys - Geospatial professional services
http://www.spatialys.com
More information about the gdal-dev
mailing list