[Lazarus] RE : Decompressing zip stream
Leonardo M. Ramé
l.rame at griensu.com
Fri Sep 2 22:14:58 CEST 2011
On 2011-09-02 21:39:47 +0200, Ludo Brands wrote:
>
> > While trying to decompress the streams using TInflater class
> > from zipper unit using this code, I get "buffer error"
> > message when calling DeCompress method. I must add that the
> > error only happens with a group of streams, specially with
> > the small ones:
> >
>
> Tdecompressionstream decompresses in chunks using an outputbuffer with the
> size you specify in TInflater.Create. When this size is too small to
> decompress a chunk you get an "buffer error". I suggest you try with a
> bigger buffersize for small files, instead of lInStream.Size. Wav files have
> a high compression ratio so a small input gives a large output.
>
> Ludo
>
Thanks Ludo for your answer.
The file size is 68127 bytes, I tried with buffer size of 2048 bytes and 100000 bytes.
In both cases I got the 'buffer error' message.
--
Leonardo M. Ramé
http://leonardorame.blogspot.com
More information about the Lazarus
mailing list