Gzip data compression More...
#include <LDM/compressors/SoGzipDataCompressor.h>
Public Member Functions | |
SoGzipDataCompressor () | |
virtual | ~SoGzipDataCompressor () |
virtual size_t | compress (void *src, size_t srcLen, const TileInfo &tileInfo) |
virtual size_t | uncompress (void *dest, size_t destLen, const TileInfo &tileInfo) |
virtual SbString | getCompressionFormatName () const |
virtual bool | isLossless () |
This class implements a compression scheme based on zlib. It is a lossless compression and can be used on any data set type.
The setCompressionLevel method (inherited from SoDataCompressor or in SoConverterParameters) accepts values between 0 and 9. 0 gives no compression, 9 gives best compression but slower speed. Default is 3.
SoJpegDataCompressor, SoDataCompressor, SoJp3dDataCompressor, SoConverterParameters
SoGzipDataCompressor::SoGzipDataCompressor | ( | ) |
Constructor.
virtual SoGzipDataCompressor::~SoGzipDataCompressor | ( | ) | [virtual] |
Destructor.
virtual size_t SoGzipDataCompressor::compress | ( | void * | src, | |
size_t | srcLen, | |||
const TileInfo & | tileInfo | |||
) | [virtual] |
Compresses the given buffer into the internal buffer.
src | a pointer to the data to compress. | |
srcLen | the size of the source buffer in bytes. | |
tileInfo | contains information about the tile being processed. |
Implements SoDataCompressor.
virtual SbString SoGzipDataCompressor::getCompressionFormatName | ( | ) | const [inline, virtual] |
Returns the name of the compression algorithm used by this class.
This is the name the user must pass to the "-c" option of the converter to use this compression ("gzip" here).
Implements SoDataCompressor.
virtual bool SoGzipDataCompressor::isLossless | ( | ) | [inline, virtual] |
This compression is lossless.
Implements SoDataCompressor.
virtual size_t SoGzipDataCompressor::uncompress | ( | void * | dest, | |
size_t | destLen, | |||
const TileInfo & | tileInfo | |||
) | [virtual] |
Uncompresses data from the internal buffer to the given buffer.
dest | a pointer to the destination buffer. | |
destLen | the size of the destination buffer. | |
tileInfo | contains information about the tile being processed |
Implements SoDataCompressor.