Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

need a gzipofstream class

13 views
Skip to first unread message

Ittay Freiman

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to
i need a class that compresses the bytes in-memory (that is, doesn't write
them to file and then compresses that file). do you know one?

thanx,
ittay

--
_______________________________________________
Ittay Freiman. (mailto:it...@tecnomatix.com)
Graphics Team. Platforms R&D. Robcad.
Tecnomatix Technologies Ltd (www.tecnomatix.com)
Delta House, 16 Ha-Galim Ave. Tel: +972-9-9594793
Herzelyia-B, 46733, Israel Fax: +972-9-9544402

Dietmar Kuehl

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to it...@tecnomatix.com
Hi,
In article <7ts0nn$hsi$1...@news.netvision.net.il>,

"Ittay Freiman" <it...@tecnomatix.com> wrote:
> i need a class that compresses the bytes in-memory (that is, doesn't
> write them to file and then compresses that file). do you know one?

For the compression have a look at zlib. This provides a C interface to
the compression and decompression used by gzip. To create an IOStream
interface to this stream, you would derive a class from 'streambuf'
which calls the zlib functions. To sent the characters to an arbitrary
destination, this stream buffer would be just a filtering stream buffer,
ie. it would get another stream buffer where the compressed stream is
read from or written to.
--
<mailto:dietma...@claas-solutions.de>
homepage: <http://www.informatik.uni-konstanz.de/~kuehl>


Sent via Deja.com http://www.deja.com/
Before you buy.

Paul

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to

zlib is at http://cdrom.com/pub/infozip/zlib

In the unsupported contrib directory of the zlib distribution there are
two iostream implementations.

--
------
Paul Scott <pms...@dera.gov.uk>

Dietmar Kuehl

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to
Hi,
In article <slrn803tm...@toilet.dera.gov.uk>,

pa...@toilet.dera.gov.uk (Paul) wrote:
> On Mon, 11 Oct 1999 10:14:12 GMT,
> Dietmar Kuehl <dietma...@claas-solutions.de> wrote:
> >In article <7ts0nn$hsi$1...@news.netvision.net.il>,
> > "Ittay Freiman" <it...@tecnomatix.com> wrote:
> >> i need a class that compresses the bytes in-memory

> zlib is at http://cdrom.com/pub/infozip/zlib

This should be <http://www.cdrom.com/pub/infozip/zlib/>.

> In the unsupported contrib directory of the zlib distribution there
> are two iostream implementations.

Neither of these two implementations uses a filtering stream buffer:
Both access files directly. This is not what was originally required.
However, these implementations might be useful as a guide when
implementing a stream buffer which does the compression and uses another
stream buffer to do the actual character I/O.

Dietmar Kuehl

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to

William Roeder

unread,
Oct 11, 1999, 3:00:00 AM10/11/99
to
Ittay Freiman wrote:
>
> i need a class that compresses the bytes in-memory (that is, doesn't write
> them to file and then compresses that file). do you know one?

Any reference book on compression should suffice

http://www.amazon.com/exec/obidos/query/%28keyword%20%3D%20%22compression%22%29
--
__ _ __ If all the world is a stage,
/ ) / / ' ) ) / where is my copy of the damn
/--' * / / /--' _ _ /> _ / _ __ script?
/__)__/\_/\_/\_ / \_(_) (__(_/\_(/_/ (_ mailto:BRo...@titan.com

0 new messages