Add option to tune for MS-SSIM

Added -tune-ms-ssim option to cjpeg to tune for multiscale SSIM metric
This commit is contained in:
Frank Bossen
2014-04-27 22:01:40 -04:00
parent 1733487e17
commit e5f8575776

View File

@@ -478,6 +478,13 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv,
cinfo->use_lambda_weight_tbl = FALSE;
jpeg_set_quality(cinfo, 75, TRUE);
} else if (keymatch(arg, "tune-ms-ssim", 6)) {
cinfo->use_flat_quant_tbl = TRUE;
cinfo->lambda_log_scale1 = 10.5;
cinfo->lambda_log_scale2 = 13.0;
cinfo->use_lambda_weight_tbl = TRUE;
jpeg_set_quality(cinfo, 75, TRUE);
} else if (keymatch(arg, "tune-hvs-psnr", 6)) {
cinfo->use_flat_quant_tbl = FALSE;
cinfo->lambda_log_scale1 = 15.0;