pub enum CompressionLevel {
Show 18 variants
None,
SuperFast,
VeryFast,
Fast,
Normal,
Optimal1,
Optimal2,
Optimal3,
Optimal4,
Optimal5,
HyperFast1,
HyperFast2,
HyperFast3,
HyperFast4,
Optimal,
HyperFast,
Max,
Min,
}
Expand description
Set of compression levels.
A compressed data stream can be decompressed with any level, but the compression level used to compress the data must be known.
The compression level controls the amount of work done by the compressor to find the best compressed bitstream. It does not directly impact decompression speed, it trades off encode speed for compression bitstream quality.
Variants§
None
Don’t compress, just copy the data
SuperFast
Lowest compression ratio, super fast
VeryFast
Fastest with still decent compression ratio
Fast
Good for daily use
Normal
Standard medium speed
Optimal1
Optimal parse level 1 (fastest)
Optimal2
Optimal parse level 2 (recommended baseline)
Optimal3
Optimal parse level 3 (slower)
Optimal4
Optimal parse level 4 (very slow)
Optimal5
Optimal parse level 5 (don’t care about speed, just want best ratio)
HyperFast1
Faster than SuperFast, but lower compression ratio
HyperFast2
Faster than HyperFast1, but lower compression ratio
HyperFast3
Faster than HyperFast2, but lower compression ratio
HyperFast4
Faster than HyperFast3, but lower compression ratio
Optimal
Alias optimal standard level
HyperFast
Alias hyperfast base level
Max
Alias for the maximum compression level
Min
Alias for the minimum compression level