Image resizer's default de-interleaved dithering class. More...
#include <avir_dil.h>
Public Member Functions | |
void | dither (fptype *const ResScanline) const |
Performs rounding and clipping operations, in-place. | |
void | init (const int aLen, const CImageResizerVars &aVars, const double aTrMul, const double aPkOut) |
Initializes the ditherer object. | |
Static Public Member Functions | |
static bool | isRecursive () |
Returns true , if dithering is recursive relative to scanlines, meaning multi-threaded execution is not supported by this dithering method. | |
Protected Attributes | |
int | Len |
Scanline's length in pixels. | |
int | LenE |
= LenE * ElCount. | |
double | PkOut0 |
Peak output value allowed. | |
double | TrMul0 |
Bit-depth truncation multiplier. | |
const CImageResizerVars * | Vars |
Image resizing-related variables. | |
Image resizer's default de-interleaved dithering class.
This class defines an object that performs rounding, clipping and dithering operations over horizontal scanline pixels before scanline is stored in the output buffer.
This ditherer implementation uses de-interleaved SIMD algorithm.
fptype | Floating point type to use for storing pixel data. SIMD types cannot be used. |
fptypesimd | The SIMD type used to store a pack of fptype values. |
void avir::CImageResizerDithererDefDIL< fptype, fptypesimd >::dither | ( | fptype *const | ResScanline | ) | const |
Performs rounding and clipping operations, in-place.
[in,out] | ResScanline | The buffer containing the final scanline. |
void avir::CImageResizerDithererDefDIL< fptype, fptypesimd >::init | ( | const int | aLen, |
const CImageResizerVars & | aVars, | ||
const double | aTrMul, | ||
const double | aPkOut ) |
Initializes the ditherer object.
aLen | Scanline length in pixels to process. |
aVars | Image resizing-related variables. |
aTrMul | Bit-depth truncation multiplier. 1 - no additional truncation. |
aPkOut | Peak output value allowed. |
|
static |
Returns true
, if dithering is recursive relative to scanlines, meaning multi-threaded execution is not supported by this dithering method.