Skip to content

Visualize quantization table compression  #4

@OmarShehata

Description

@OmarShehata

Currently the slider "compresses" the image by zero-ing out DCT components in order of highest weight.

This is not quite how JPEG works in practice. To apply compression, you divide each component by a specific constant factor. These constants for each component are specified in a quantization table.

The values in the quantization table are chosen to preserve low-frequency information and discard high-frequency (noise-like) detail as humans are less critical to the loss of information in this area.

From: http://www.robertstocker.co.uk/jpeg/jpeg_new_10.htm

So it could be interesting to compare compressing using different quantization tables. Or simply as someone suggested on Twitter: zero-out the components by the zig zag order (highest frequency to lowest) which is generally how the quantization tables are designed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions