JP3D data compression More...
#include <LDM/compressors/SoJp3dDataCompressor.h>
Public Member Functions | |
SoJp3dDataCompressor () | |
virtual | ~SoJp3dDataCompressor () |
virtual SbString | getCompressionFormatName () const |
virtual bool | isLossless () |
virtual size_t | compress (void *src, size_t srcLen, const TileInfo &tileInfo) |
virtual size_t | uncompress (void *dst, size_t dstLen, const TileInfo &tileInfo) |
This class implements a wavelet compression scheme based on JP3D compression, an extension of the standard JPEG2000 algorithms specifically designed for volume data. It supports lossless and lossy compression. This is controlled by setCompressionLevel (see SoDataCompressor or SoConvertedParameters). A compression level of 0 specifies the lossless mode. Any other value specifies the target PSNR (Peak Signal to Noise Ratio).
Typical values for compression level (PSNR):
Limitations:
SoGzipDataCompressor, SoJpegDataCompressor, SoDataCompressor, SoConverterParameters
SoJp3dDataCompressor::SoJp3dDataCompressor | ( | ) |
Constructor.
virtual SoJp3dDataCompressor::~SoJp3dDataCompressor | ( | ) | [virtual] |
Destructor.
virtual size_t SoJp3dDataCompressor::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 SoJp3dDataCompressor::getCompressionFormatName | ( | ) | const [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 ("jp3d" here).
Implements SoDataCompressor.
virtual bool SoJp3dDataCompressor::isLossless | ( | ) | [virtual] |
Checks if the compression is lossless.
The lossless mode is active if the compression level is 0 (the default).
Implements SoDataCompressor.
virtual size_t SoJp3dDataCompressor::uncompress | ( | void * | dst, | |
size_t | dstLen, | |||
const TileInfo & | tileInfo | |||
) | [virtual] |
Uncompresses data from the internal buffer to the given buffer.
dst | a pointer to the destination buffer. | |
dstLen | the size of the destination buffer. | |
tileInfo | contains information about the tile being processed |
Implements SoDataCompressor.