mozjpeg icon indicating copy to clipboard operation
mozjpeg copied to clipboard

Trellis documentation lacking

Open nagnug opened this issue 11 years ago • 1 comments
trafficstars

There needs to be explanation of the trellis feature, how it works, what else in the encoding process it interacts with. My interest is in quantization tables, so I want to know how the final matrix values are calculated with trellis enabled.

nagnug avatar Oct 16 '14 18:10 nagnug

The trellis feature essentially replaces the quantization block in the encoder. However the decoder is not modified and the quantization tables are not affected by the trellis feature. Give a quantization table the trellis process finds quantized transform coefficient values that minimize a rate-distortion metric of the form R + lambda*D. Note that when tuning for certain metrics such as PSNR and SSIM, a flat matrix is used instead of the default (JPEG Annex K) one.

fbossen avatar Oct 21 '14 14:10 fbossen