Value | Meaning |
---|---|
Normal-1 | Default compression level. This is selected for a good compromise between speed and compression, and the exact compression level is determined by the underlying zlib library. Should be roughly equivalent to compression level 6. |
None0 | Do not perform compression. This will cause the stream to expand slightly to accommodate stream metadata. |
Fast1 | Minimal compression; the fastest level which performs at least some compression. |
Best9 | Maximal compression. |
This enumeration represents several pre-defined compression levels.
Any integer between -1 and 9 inclusive may be used as a level, although the symbols in this enumeration should suffice for most use-cases.