Panda3D
Public Member Functions | List of all members
OCompressStream Class Reference

An input stream object that uses zlib to compress (deflate) data to another destination stream on-the-fly. More...

Inheritance diagram for OCompressStream:
Ostream BasicIosChar IosBase

Public Member Functions

 __init__ ()
 
 __init__ (Ostream dest, bool owns_dest, int compression_level)
 
OCompressStream close ()
 Resets the ZStream to empty, but does not actually close the dest ostream unless owns_dest was true. More...
 
OCompressStream open (Ostream dest, bool owns_dest, int compression_level)
 
- Public Member Functions inherited from Ostream
 flush ()
 
 put (char c)
 
 seekp (Streamoff pos)
 
 seekp (Streamoff off, IosBase::Seekdir dir)
 
Streamoff tellp ()
 
- Public Member Functions inherited from BasicIosChar
bool bad ()
 
 clear ()
 
bool eof ()
 
bool fail ()
 
bool good ()
 

Additional Inherited Members

- Public Types inherited from IosBase
enum  Iostate
 
enum  Openmode
 
enum  Seekdir { beg = 0, cur = 1, end = 2 }
 

Detailed Description

An input stream object that uses zlib to compress (deflate) data to another destination stream on-the-fly.

Attach an OCompressStream to an existing ostream that will accept compressed data, and write your uncompressed source data to the OCompressStream.

Seeking is not supported.

Member Function Documentation

◆ __init__() [1/2]

__init__ ( )

◆ __init__() [2/2]

__init__ ( Ostream  dest,
bool  owns_dest,
int  compression_level 
)

◆ close()

OCompressStream close ( )

Resets the ZStream to empty, but does not actually close the dest ostream unless owns_dest was true.

◆ open()

OCompressStream open ( Ostream  dest,
bool  owns_dest,
int  compression_level 
)