Grok 10.0.5
grk::grk::mct Class Reference

#include <TileCache.h>

Public Member Functions

 mct (Tile *tile, GrkImage *image, TileCodingParams *tcp, StripCache *stripCache)
 
void compress_rev (FlowComponent *flow)
 Apply a reversible multi-component transform to an image.
 
void decompress_rev (FlowComponent *flow)
 Apply a reversible multi-component inverse transform to an image.
 
void compress_irrev (FlowComponent *flow)
 Apply an irreversible multi-component transform to an image.
 
void decompress_irrev (FlowComponent *flow)
 Apply an irreversible multi-component inverse transform to an image.
 
void decompress_dc_shift_rev (FlowComponent *flow, uint16_t compno)
 Apply a reversible inverse dc shift to an image.
 
void decompress_dc_shift_irrev (FlowComponent *flow, uint16_t compno)
 Apply an irreversible inverse dc shift to an image.
 

Static Public Member Functions

static const double * get_norms_rev (void)
 Get wavelet norms for reversible transform.
 
static const double * get_norms_irrev (void)
 Get wavelet norms for irreversible transform.
 
static bool compress_custom (uint8_t *p_coding_data, uint64_t n, uint8_t **p_data, uint16_t numComps, uint32_t is_signed)
 Custom MCT transform.
 
static bool decompress_custom (uint8_t *pDecodingData, uint64_t n, uint8_t **pData, uint16_t pNbComp, uint32_t isSigned)
 Custom MCT decode.
 
static void calculate_norms (double *pNorms, uint16_t nb_comps, float *pMatrix)
 Calculate norm of MCT transform.
 

Private Member Functions

void genShift (uint16_t compno, int32_t sign, std::vector< ShiftInfo > &shiftInfo)
 
void genShift (int32_t sign, std::vector< ShiftInfo > &shiftInfo)
 

Private Attributes

Tiletile_
 
GrkImageimage_
 
TileCodingParamstcp_
 
StripCachestripCache_
 

Constructor & Destructor Documentation

◆ mct()

grk::mct::mct ( Tile * tile,
GrkImage * image,
TileCodingParams * tcp,
StripCache * stripCache )

Member Function Documentation

◆ calculate_norms()

static void grk::mct::calculate_norms ( double * pNorms,
uint16_t nb_comps,
float * pMatrix )
static

Calculate norm of MCT transform.

Parameters
pNormsMCT data
nb_compsnumber of components
pMatrixcomponents

◆ compress_custom()

static bool grk::mct::compress_custom ( uint8_t * p_coding_data,
uint64_t n,
uint8_t ** p_data,
uint16_t numComps,
uint32_t is_signed )
static

Custom MCT transform.

Parameters
p_coding_dataMCT data
nsize of components
p_datacomponents
numCompsnb of components (i.e. size of p_data)
is_signedindicates if the data is signed
Returns
false if function encounter a problem, true otherwise

References data, grk::fix_mul(), grk::grk_free(), and grk::grk_malloc().

◆ compress_irrev()

void grk::mct::compress_irrev ( FlowComponent * flow)

Apply an irreversible multi-component transform to an image.

References HWY_DYNAMIC_DISPATCH, grk::grk::ScheduleInfo::shiftInfo, grk::singleTileRowsPerStrip, and tile_.

◆ compress_rev()

void grk::mct::compress_rev ( FlowComponent * flow)

Apply a reversible multi-component transform to an image.

References HWY_DYNAMIC_DISPATCH, grk::grk::ScheduleInfo::shiftInfo, grk::singleTileRowsPerStrip, and tile_.

◆ decompress_custom()

static bool grk::mct::decompress_custom ( uint8_t * pDecodingData,
uint64_t n,
uint8_t ** pData,
uint16_t pNbComp,
uint32_t isSigned )
static

Custom MCT decode.

Parameters
pDecodingDataMCT data
nsize of components
pDatacomponents
pNbCompnb of components (i.e. size of p_data)
isSignedtells if the data is signed
Returns
false if function encounter a problem, true otherwise

References data.

◆ decompress_dc_shift_irrev()

void grk::mct::decompress_dc_shift_irrev ( FlowComponent * flow,
uint16_t compno )

Apply an irreversible inverse dc shift to an image.

References compno, grk::grk::ScheduleInfo::compno, HWY_DYNAMIC_DISPATCH, image_, grk::grk::ScheduleInfo::shiftInfo, stripCache_, and tile_.

◆ decompress_dc_shift_rev()

void grk::mct::decompress_dc_shift_rev ( FlowComponent * flow,
uint16_t compno )

Apply a reversible inverse dc shift to an image.

References compno, grk::grk::ScheduleInfo::compno, HWY_DYNAMIC_DISPATCH, image_, grk::grk::ScheduleInfo::shiftInfo, stripCache_, and tile_.

◆ decompress_irrev()

void grk::mct::decompress_irrev ( FlowComponent * flow)

Apply an irreversible multi-component inverse transform to an image.

inverse irreversible MCT (with dc shift) (vector routines are disabled)

References hwy::DisableTargets(), HWY_DYNAMIC_DISPATCH, HWY_SCALAR, image_, grk::grk::ScheduleInfo::shiftInfo, stripCache_, and tile_.

◆ decompress_rev()

void grk::mct::decompress_rev ( FlowComponent * flow)

Apply a reversible multi-component inverse transform to an image.

References HWY_DYNAMIC_DISPATCH, image_, grk::grk::ScheduleInfo::shiftInfo, stripCache_, and tile_.

◆ genShift() [1/2]

void grk::mct::genShift ( int32_t sign,
std::vector< ShiftInfo > & shiftInfo )
private

References shiftInfo.

◆ genShift() [2/2]

void grk::mct::genShift ( uint16_t compno,
int32_t sign,
std::vector< ShiftInfo > & shiftInfo )
private

References _max, _min, compno, image_, grk::shift, shiftInfo, and tcp_.

◆ get_norms_irrev()

static const double * grk::mct::get_norms_irrev ( void )
static

Get wavelet norms for irreversible transform.

References grk::mct_norms_irrev.

◆ get_norms_rev()

static const double * grk::mct::get_norms_rev ( void )
static

Get wavelet norms for reversible transform.

References grk::mct_norms_rev.

Member Data Documentation

◆ image_

GrkImage* grk::grk::mct::image_
private

◆ stripCache_

StripCache * grk::mct::stripCache_
private

◆ tcp_

TileCodingParams* grk::grk::mct::tcp_
private

◆ tile_

Tile* grk::grk::mct::tile_
private

The documentation for this class was generated from the following files: