Using version 7.0.3:
results in a 5625k file (I'll use this as a reference)
Code: Select all
magick img_0369.jpg -format jp2 -define jp2:rate=16 img_0369_16.jp2
results in a 351k file which is exactly 16:1 compression rate.
Code: Select all
magick img_0369.jpg -format jp2 -quality 75 img_0369_75.jp2
results in a 1684k file which contradicts the documentation here:
https://www.imagemagick.org/script/comm ... hp#quality which says clearly that a quality of 75 is a close equivalent to a 16:1 compression rate.
Using version 6.8.6-10:
Code: Select all
convert img_0369.jpg -format jp2 -define jp2:rate=0.0625 img_0369_16_1.jp2
results in a 351k file which is exactly 16:1 compression rate (1/16 = 0.0625)
Note: JP2 options are different then in 7.x
JP2 Encoding Options:
rate=r
Specify the target rate. The argument r is a positive real number.
Since a rate of one corresponds to no compression, one should
never need to explicitly specify a rate greater than one. By
default, the target rate is considered to be infinite.
Code: Select all
convert img_0369.jpg -format jp2 -quality 75 img_0369_75.jp2
results in a 352k file which is very close to 16:1 compression rate, which is correct.
=======================================================
Is this a bug in ImageMagick 7.0.3, a change in behaviour
(I'd say for the worse) or is it an issue with libopenjpeg?