Skip to content
Andrew Lambert edited this page Dec 19, 2016 · 14 revisions

#zlib.ZStream.Level

##Property declaration

 Dim Level As Integer

##Notes Gets and sets the compression level for the stream. Valid levels are Z_BEST_SPEED(1) to Z_BEST_COMPRESSION(9). 0 means no compression. Specify Z_DEFAULT_COMPRESSION(-1) to use the default level, which is equivalent to level 6.

The compression level controls the tradeoff between compression speed and compression ratio. Faster compression results in worse compression ratios.

Changes to this property will effect subsequent calls to Write. Input from previous calls to Write which have already been fed to the compressor but not yet to be emitted as output will use the previous Level.

##See also

Entry-level points of interest denoted by "☜"



Clone this wiki locally