#include <Compression.h>
The H-compress algorithm.
This algorithm relies on some scaling parameter. When scaling is enabled, H-compress is lossy irrespective of quantization. In order to use H-compress losslessly, quantization and scaling must be zeroed, and the data values must be integers.
Analogously to quantization, the scaling can be set globally or tile-wise, which is recommended. In the latter case, it is generally provided as a multiplicative factor of the noise RMS:
Public Member Functions | |
HCompress (Position<-1 > tiling=Tile::adaptive(), Quantization quantization=Quantization(), Scaling scaling=Scaling(0)) | |
Constructor. | |
bool | is_lossless () const override |
Check whether compression is lossless. More... | |
const Quantization & | quantization () const |
Get the quantization. | |
HCompress & | quantization (Quantization quantization) override |
Set the quantization. More... | |
const Scaling & | scaling () const |
Get the scaling parameter. | |
HCompress & | scaling (Scaling scale) |
Set the scaling parameter. | |
Public Member Functions inherited from AlgoMixin< HCompress > | |
const Quantization & | quantization () const |
Get the quantization. | |
virtual HCompress & | quantization (Quantization quantization) |
Set the quantization. More... | |
const Position<-1 > & | tiling () const |
Get the tiling. | |
virtual HCompress & | tiling (Position<-1 > shape) |
Set the tiling. | |
Public Member Functions inherited from Compression | |
virtual bool | is_lossless () const |
Check whether the compression is lossless for. More... | |
const Quantization & | quantization () const |
Get the quantization. | |
const Position<-1 > & | tiling () const |
Get the tiling. | |