Grok  9.5.0
Public Member Functions | Private Member Functions | Private Attributes | List of all members
grk::TileComponentWindowBuffer< T > Struct Template Reference

#include <TileComponentWindowBuffer.h>

Public Member Functions

 TileComponentWindowBuffer (bool isCompressor, bool lossless, bool wholeTileDecompress, grkRectU32 tileCompUnreduced, grkRectU32 tileCompReduced, grkRectU32 unreducedTileCompOrImageCompWindow, Resolution *tileCompResolution, uint8_t numresolutions, uint8_t reducedNumResolutions)
 
 ~TileComponentWindowBuffer ()
 
void toRelativeCoordinates (uint8_t resno, eBandOrientation orientation, uint32_t &offsetx, uint32_t &offsety) const
 Transform code block offsets from canvas coordinates to either band coordinates (relative to sub band origin) or buffer coordinates (relative to associated resolution origin) More...
 
const grkBuffer2d< T, AllocatorAligned > * getCodeBlockDestWindowREL (uint8_t resno, eBandOrientation orientation) const
 Get code block destination window. More...
 
const grkBuffer2d< T, AllocatorAligned > * getBandWindowBufferPaddedREL (uint8_t resno, eBandOrientation orientation) const
 Get padded band window buffer. More...
 
const grkRectU32getBandWindowPadded (uint8_t resno, eBandOrientation orientation) const
 Get padded band window. More...
 
const grkBuffer2d< T, AllocatorAligned > * getResWindowBufferSplitREL (uint8_t resno, eSplitOrientation orientation) const
 
const grkBuffer2d< T, AllocatorAligned > * getResWindowBufferREL (uint32_t resno) const
 Get resolution window. More...
 
grkBuffer2d< T, AllocatorAligned > * getResWindowBufferHighestREL (void) const
 Get highest resolution window. More...
 
bool alloc ()
 
grkRectU32 bounds () const
 Get bounds of tile component (canvas coordinates) decompress: reduced canvas coordinates of window compress: unreduced canvas coordinates of entire tile. More...
 
grkRectU32 unreducedBounds () const
 
uint64_t stridedArea (void) const
 
void attach (T *buffer, uint32_t stride)
 
void transfer (T **buffer, uint32_t *stride)
 

Private Member Functions

bool useBandWindows () const
 
bool useBufferCoordinatesForCodeblock () const
 
uint8_t getBandIndex (uint8_t resno, eBandOrientation orientation) const
 

Private Attributes

grkRectU32 m_unreducedBounds
 
grkRectU32 m_bounds
 
std::vector< Resolution * > m_resolution
 
std::vector< ResWindowBuffer< T > * > m_resWindowBufferREL
 
uint8_t m_numResolutions
 
bool m_compress
 
bool m_wholeTileDecompress
 

Constructor & Destructor Documentation

◆ TileComponentWindowBuffer()

template<typename T >
grk::TileComponentWindowBuffer< T >::TileComponentWindowBuffer ( bool  isCompressor,
bool  lossless,
bool  wholeTileDecompress,
grkRectU32  tileCompUnreduced,
grkRectU32  tileCompReduced,
grkRectU32  unreducedTileCompOrImageCompWindow,
Resolution tileCompResolution,
uint8_t  numresolutions,
uint8_t  reducedNumResolutions 
)
inline

◆ ~TileComponentWindowBuffer()

template<typename T >
grk::TileComponentWindowBuffer< T >::~TileComponentWindowBuffer ( )
inline

Member Function Documentation

◆ alloc()

template<typename T >
bool grk::TileComponentWindowBuffer< T >::alloc ( )
inline

◆ attach()

template<typename T >
void grk::TileComponentWindowBuffer< T >::attach ( T *  buffer,
uint32_t  stride 
)
inline

◆ bounds()

template<typename T >
grkRectU32 grk::TileComponentWindowBuffer< T >::bounds ( ) const
inline

Get bounds of tile component (canvas coordinates) decompress: reduced canvas coordinates of window compress: unreduced canvas coordinates of entire tile.

References grk::TileComponentWindowBuffer< T >::m_bounds.

Referenced by grk::GrkImage::duplicate(), grk::GrkImage::generateCompositeBounds(), and grk::TileProcessor::isWholeTileDecompress().

◆ getBandIndex()

template<typename T >
uint8_t grk::TileComponentWindowBuffer< T >::getBandIndex ( uint8_t  resno,
eBandOrientation  orientation 
) const
inlineprivate

◆ getBandWindowBufferPaddedREL()

template<typename T >
const grkBuffer2d<T, AllocatorAligned>* grk::TileComponentWindowBuffer< T >::getBandWindowBufferPaddedREL ( uint8_t  resno,
eBandOrientation  orientation 
) const
inline

Get padded band window buffer.

Parameters
resnoresolution number
orientationband orientation {0,1,2,3} for {LL,HL,LH,HH} band windows

If resno is > 0, return LL,HL,LH or HH band window, otherwise return LL resolution window

References grk::BAND_ORIENT_LL, grk::TileComponentWindowBuffer< T >::m_compress, grk::TileComponentWindowBuffer< T >::m_resolution, grk::TileComponentWindowBuffer< T >::m_resWindowBufferREL, and grk::TileComponentWindowBuffer< T >::m_wholeTileDecompress.

Referenced by grk::TileComponentWindowBuffer< T >::getCodeBlockDestWindowREL().

◆ getBandWindowPadded()

template<typename T >
const grkRectU32* grk::TileComponentWindowBuffer< T >::getBandWindowPadded ( uint8_t  resno,
eBandOrientation  orientation 
) const
inline

Get padded band window.

Parameters
resnoresolution number
orientationband orientation {0,1,2,3} for {LL,HL,LH,HH} band windows

References grk::TileComponentWindowBuffer< T >::m_resWindowBufferREL.

Referenced by grk::TileComponent::allocSparseCanvas(), grk::T1DecompressScheduler::prepareScheduleDecompress(), and grk::TileComponent::subbandIntersectsAOI().

◆ getCodeBlockDestWindowREL()

template<typename T >
const grkBuffer2d<T, AllocatorAligned>* grk::TileComponentWindowBuffer< T >::getCodeBlockDestWindowREL ( uint8_t  resno,
eBandOrientation  orientation 
) const
inline

◆ getResWindowBufferHighestREL()

template<typename T >
grkBuffer2d<T, AllocatorAligned>* grk::TileComponentWindowBuffer< T >::getResWindowBufferHighestREL ( void  ) const
inline

◆ getResWindowBufferREL()

template<typename T >
const grkBuffer2d<T, AllocatorAligned>* grk::TileComponentWindowBuffer< T >::getResWindowBufferREL ( uint32_t  resno) const
inline

Get resolution window.

Parameters
resnoresolution number

References grk::TileComponentWindowBuffer< T >::m_resWindowBufferREL.

◆ getResWindowBufferSplitREL()

template<typename T >
const grkBuffer2d<T, AllocatorAligned>* grk::TileComponentWindowBuffer< T >::getResWindowBufferSplitREL ( uint8_t  resno,
eSplitOrientation  orientation 
) const
inline

◆ stridedArea()

template<typename T >
uint64_t grk::TileComponentWindowBuffer< T >::stridedArea ( void  ) const
inline

◆ toRelativeCoordinates()

template<typename T >
void grk::TileComponentWindowBuffer< T >::toRelativeCoordinates ( uint8_t  resno,
eBandOrientation  orientation,
uint32_t &  offsetx,
uint32_t &  offsety 
) const
inline

Transform code block offsets from canvas coordinates to either band coordinates (relative to sub band origin) or buffer coordinates (relative to associated resolution origin)

Parameters
resnoresolution number
orientationband orientation {LL,HL,LH,HH}
offsetxx offset of code block in canvas coordinates
offsetyy offset of code block in canvas coordinates

References grk::TileComponentWindowBuffer< T >::getBandIndex(), grk::TileComponentWindowBuffer< T >::m_resolution, and grk::TileComponentWindowBuffer< T >::useBufferCoordinatesForCodeblock().

Referenced by grk::TileComponent::postDecompressImpl().

◆ transfer()

template<typename T >
void grk::TileComponentWindowBuffer< T >::transfer ( T **  buffer,
uint32_t *  stride 
)
inline

◆ unreducedBounds()

template<typename T >
grkRectU32 grk::TileComponentWindowBuffer< T >::unreducedBounds ( ) const
inline

◆ useBandWindows()

template<typename T >
bool grk::TileComponentWindowBuffer< T >::useBandWindows ( ) const
inlineprivate

◆ useBufferCoordinatesForCodeblock()

template<typename T >
bool grk::TileComponentWindowBuffer< T >::useBufferCoordinatesForCodeblock ( ) const
inlineprivate

Member Data Documentation

◆ m_bounds

template<typename T >
grkRectU32 grk::TileComponentWindowBuffer< T >::m_bounds
private

◆ m_compress

template<typename T >
bool grk::TileComponentWindowBuffer< T >::m_compress
private

◆ m_numResolutions

template<typename T >
uint8_t grk::TileComponentWindowBuffer< T >::m_numResolutions
private

◆ m_resolution

template<typename T >
std::vector<Resolution*> grk::TileComponentWindowBuffer< T >::m_resolution
private

◆ m_resWindowBufferREL

template<typename T >
std::vector<ResWindowBuffer<T>*> grk::TileComponentWindowBuffer< T >::m_resWindowBufferREL
private

◆ m_unreducedBounds

template<typename T >
grkRectU32 grk::TileComponentWindowBuffer< T >::m_unreducedBounds
private

◆ m_wholeTileDecompress

template<typename T >
bool grk::TileComponentWindowBuffer< T >::m_wholeTileDecompress
private

The documentation for this struct was generated from the following file: