Re: System.IO.Compression

Tech-Archive recommends: Speed Up your PC by fixing your registry



Mark Rae wrote:
> > You could decompress by writing each decompressed chunk you read into a
> > MemoryStream instead, then get the array after that. You might waste a
> > bit of time/memory copying things around, but it would only need to
> > read the data once.
>
> Yes, I see what you're saying.
>
> I'm also reading quite a few postings around the net that the new
> System.IO.Compression functionality "isn't very good", at least not for file
> compression / decompression - is this the general consensus around here?

Well, it's somewhat limited in terms of it being solely stream
compression - zip files themselves can't be extracted, etc. I don't
know much more about it than that though.

> The 3rd-party component I've been using up to now is available for .NET2, so
> I might just continue to use it anyway...

SharpZipLib by any chance? I've used that too, and it works well -
although there's a bug which I reported a while ago which worried me
somewhat. (It was unable to decompress its own compressed data.) It may
have been fixed by now, of course...

Jon

.



Relevant Pages

  • Re: [PATCH] init: bzip2 or lzma -compressed kernels and initrds
    ... Compression is slowest. ... The kernel size is about 33 per cent smaller with lzma, ... I guess this is done on the internal hard disk of the laptop (this is ... disk, decompress, write to disk. ...
    (Linux-Kernel)
  • Re: zlib and zip files
    ... I need to decompress zip archive. ... The zlib module is for reading and writing the gzip compression format, used by the gzip program; it is not the same as a zip archive a la PKZip. ... The zipfile module will let you read and write zip archives. ... The gzip compressor and decompressor can work on the fly, but the format that it produces is a bit other than the format of compressed data zipfile. ...
    (comp.lang.python)
  • Re: copyng large compressed files
    ... buffer. ... transparent compression. ... To read a file you need to decompress it. ... overhead of decompress. ...
    (comp.lang.java.advocacy)
  • Compression for small-memory devices
    ... The microcontroller only needs to decompress the stream from Flash memory, the compression is done on a normal PC. ... that all the LZ algorithms I saw need some RAM space to hold a sliding window on the decoder side -- LZ codes the offset/length pairs in respect to the decoded stream. ...
    (comp.compression)
  • Re: Reverse-engineering an LZSS compression routine (on a Hitachi H8)
    ... > I need to do to write a C program to decompress the images. ... but my disassembler reports that the decompressed ... is much easier than compression, you don't have to worry about ...
    (comp.arch.embedded)