Grok 10.0.5
Public Member Functions | Private Member Functions | Private Attributes | List of all members
grk::PacketIter Struct Reference

Packet iterator. More...

#include <PacketIter.h>

Public Member Functions

 PacketIter ()
 
 ~PacketIter ()
 
void init (PacketManager *packetMan, uint32_t pino, TileCodingParams *tcp, grk_rect32 tileBounds, bool compression, uint8_t max_res, uint64_t max_precincts, uint32_t *resolutionPrecinctGrid, uint32_t **precinctByComponent)
 
void printStaticState (void)
 
void printDynamicState (void)
 
void enableTilePartGeneration (uint32_t pino, bool first_poc_tile_part, uint32_t tppos)
 Modify the packet iterator for enabling tile part generation.
 
bool genPrecinctInfoOPT ()
 
void genPrecinctInfo ()
 
void genPrecinctInfo (PiComp *comp, PiResolution *res, uint8_t resNumber)
 
uint8_tget_include (uint16_t layerIndex)
 
bool update_include (void)
 
void destroy_include (void)
 
bool next (SparseBuffer *src)
 Modify the packet iterator to point to the next packet.
 
GRK_PROG_ORDER getProgression (void) const
 
uint16_t getCompno (void) const
 
uint8_t getResno (void) const
 
uint64_t getPrecinctIndex (void) const
 
uint16_t getLayno (void) const
 

Private Member Functions

void update_dxy (void)
 
bool checkForRemainingValidProgression (int32_t prog, uint32_t pino, const char *progString)
 Check if there is a remaining valid progression order.
 
bool genPrecinctY0Grid (ResPrecinctInfo *rpInfo)
 
bool genPrecinctX0Grid (ResPrecinctInfo *rpInfo)
 
void genPrecinctY0GridRPCL_OPT (ResPrecinctInfo *rpInfo)
 
void genPrecinctX0GridRPCL_OPT (ResPrecinctInfo *rpInfo)
 
bool genPrecinctX0GridPCRL_OPT (ResPrecinctInfo *rpInfo)
 
bool genPrecinctY0GridPCRL_OPT (ResPrecinctInfo *rpInfo)
 
bool precInfoCheck (ResPrecinctInfo *rpInfo)
 
void generatePrecinctIndex (void)
 
bool validatePrecinct (void)
 
void update_dxy_for_comp (PiComp *comp, bool updateActive)
 
bool isWholeTile (void)
 
bool next_cprl (SparseBuffer *src)
 Get next packet in component-precinct-resolution-layer order.
 
bool next_cprlOPT (SparseBuffer *src)
 
bool next_pcrl (SparseBuffer *src)
 Get next packet in precinct-component-resolution-layer order.
 
bool next_pcrlOPT (SparseBuffer *src)
 
bool next_lrcp (SparseBuffer *src)
 Get next packet in layer-resolution-component-precinct order.
 
bool next_lrcpOPT (SparseBuffer *src)
 
bool next_rlcp (SparseBuffer *src)
 Get next packet in resolution-layer-component-precinct order.
 
bool next_rlcpOPT (SparseBuffer *src)
 
bool next_rpcl (SparseBuffer *src)
 Get next packet in resolution-precinct-component-layer order.
 
bool next_rpclOPT (SparseBuffer *src)
 
bool skipPackets (SparseBuffer *src, uint64_t numPackets)
 

Private Attributes

uint16_t compno
 
uint8_t resno
 
uint64_t precinctIndex
 
uint16_t layno
 
grk_progression prog
 
uint16_t numcomps
 
PiCompcomps
 
uint64_t x
 packet coordinates
 
uint64_t y
 
uint32_t dx
 component sub-sampling
 
uint32_t dy
 
uint32_t dxActive
 
uint32_t dyActive
 
bool incrementInner
 
PacketManagerpacketManager
 
uint8_t maxNumDecompositionResolutions
 
bool singleProgression_
 
bool compression_
 
ResPrecinctInfoprecinctInfoOPT_
 
uint32_t px0grid_
 
uint32_t py0grid_
 
bool skippedLeft_
 

Detailed Description

Packet iterator.

Constructor & Destructor Documentation

◆ PacketIter()

grk::PacketIter::PacketIter ( )

References grk::grk_read(), and prog.

◆ ~PacketIter()

grk::PacketIter::~PacketIter ( )

References comps, and precinctInfoOPT_.

Member Function Documentation

◆ checkForRemainingValidProgression()

bool grk::PacketIter::checkForRemainingValidProgression ( int32_t  prog,
uint32_t  pino,
const char progString 
)
private

◆ destroy_include()

void grk::PacketIter::destroy_include ( void  )

◆ enableTilePartGeneration()

void grk::PacketIter::enableTilePartGeneration ( uint32_t  pino,
bool  first_poc_tile_part,
uint32_t  tppos 
)

◆ generatePrecinctIndex()

void grk::PacketIter::generatePrecinctIndex ( void  )
private

◆ genPrecinctInfo() [1/2]

void grk::PacketIter::genPrecinctInfo ( )

◆ genPrecinctInfo() [2/2]

void grk::PacketIter::genPrecinctInfo ( PiComp comp,
PiResolution res,
uint8_t  resNumber 
)

◆ genPrecinctInfoOPT()

bool grk::PacketIter::genPrecinctInfoOPT ( void  )

◆ genPrecinctX0Grid()

bool grk::PacketIter::genPrecinctX0Grid ( ResPrecinctInfo rpInfo)
private

◆ genPrecinctX0GridPCRL_OPT()

bool grk::PacketIter::genPrecinctX0GridPCRL_OPT ( ResPrecinctInfo rpInfo)
private

◆ genPrecinctX0GridRPCL_OPT()

void grk::PacketIter::genPrecinctX0GridRPCL_OPT ( ResPrecinctInfo rpInfo)
private

References grk::ceildivpow2(), grk::grk_read(), px0grid_, and x.

Referenced by next_rpclOPT().

◆ genPrecinctY0Grid()

bool grk::PacketIter::genPrecinctY0Grid ( ResPrecinctInfo rpInfo)
private

◆ genPrecinctY0GridPCRL_OPT()

bool grk::PacketIter::genPrecinctY0GridPCRL_OPT ( ResPrecinctInfo rpInfo)
private

◆ genPrecinctY0GridRPCL_OPT()

void grk::PacketIter::genPrecinctY0GridRPCL_OPT ( ResPrecinctInfo rpInfo)
private

References grk::ceildivpow2(), grk::grk_read(), py0grid_, and y.

Referenced by next_rpclOPT().

◆ get_include()

uint8_t * grk::PacketIter::get_include ( uint16_t  layerIndex)

◆ getCompno()

uint16_t grk::PacketIter::getCompno ( void  ) const

References compno.

◆ getLayno()

uint16_t grk::PacketIter::getLayno ( void  ) const

References layno.

◆ getPrecinctIndex()

uint64_t grk::PacketIter::getPrecinctIndex ( void  ) const

References precinctIndex.

◆ getProgression()

GRK_PROG_ORDER grk::PacketIter::getProgression ( void  ) const

◆ getResno()

uint8_t grk::PacketIter::getResno ( void  ) const

References resno.

◆ init()

void grk::PacketIter::init ( PacketManager packetMan,
uint32_t  pino,
TileCodingParams tcp,
grk_rect32  tileBounds,
bool  compression,
uint8_t  max_res,
uint64_t  max_precincts,
uint32_t resolutionPrecinctGrid,
uint32_t **  precinctByComponent 
)

◆ isWholeTile()

bool grk::PacketIter::isWholeTile ( void  )
private

◆ next()

bool grk::PacketIter::next ( SparseBuffer src)

Modify the packet iterator to point to the next packet.

Returns
false if pi pointed to the final packet, otherwise true

References GRK_CPRL, GRK_LRCP, GRK_PCRL, grk::grk_read(), GRK_RLCP, GRK_RPCL, next_cprl(), next_lrcp(), next_pcrl(), next_rlcp(), next_rpcl(), prog, and _grk_progression::progression.

◆ next_cprl()

bool grk::PacketIter::next_cprl ( SparseBuffer src)
private

◆ next_cprlOPT()

bool grk::PacketIter::next_cprlOPT ( SparseBuffer src)
private

◆ next_lrcp()

bool grk::PacketIter::next_lrcp ( SparseBuffer src)
private

◆ next_lrcpOPT()

bool grk::PacketIter::next_lrcpOPT ( SparseBuffer src)
private

◆ next_pcrl()

bool grk::PacketIter::next_pcrl ( SparseBuffer src)
private

◆ next_pcrlOPT()

bool grk::PacketIter::next_pcrlOPT ( SparseBuffer src)
private

◆ next_rlcp()

bool grk::PacketIter::next_rlcp ( SparseBuffer src)
private

◆ next_rlcpOPT()

bool grk::PacketIter::next_rlcpOPT ( SparseBuffer src)
private

◆ next_rpcl()

bool grk::PacketIter::next_rpcl ( SparseBuffer src)
private

◆ next_rpclOPT()

bool grk::PacketIter::next_rpclOPT ( SparseBuffer src)
private

◆ precInfoCheck()

bool grk::PacketIter::precInfoCheck ( ResPrecinctInfo rpInfo)
private

◆ printDynamicState()

void grk::PacketIter::printDynamicState ( void  )

◆ printStaticState()

void grk::PacketIter::printStaticState ( void  )

◆ skipPackets()

bool grk::PacketIter::skipPackets ( SparseBuffer src,
uint64_t  numPackets 
)
private

◆ update_dxy()

void grk::PacketIter::update_dxy ( void  )
private

◆ update_dxy_for_comp()

void grk::PacketIter::update_dxy_for_comp ( PiComp comp,
bool  updateActive 
)
private

References dx, dxActive, dy, dyActive, grk::grk_read(), resno, x, and y.

Referenced by next_cprl(), and update_dxy().

◆ update_include()

bool grk::PacketIter::update_include ( void  )

◆ validatePrecinct()

bool grk::PacketIter::validatePrecinct ( void  )
private

Member Data Documentation

◆ compno

uint16_t grk::PacketIter::compno
private

◆ compression_

bool grk::PacketIter::compression_
private

◆ comps

PiComp* grk::PacketIter::comps
private

◆ dx

uint32_t grk::PacketIter::dx
private

◆ dxActive

uint32_t grk::PacketIter::dxActive
private

◆ dy

uint32_t grk::PacketIter::dy
private

◆ dyActive

uint32_t grk::PacketIter::dyActive
private

◆ incrementInner

bool grk::PacketIter::incrementInner
private

◆ layno

uint16_t grk::PacketIter::layno
private

◆ maxNumDecompositionResolutions

uint8_t grk::PacketIter::maxNumDecompositionResolutions
private

Referenced by init(), and next_rpclOPT().

◆ numcomps

uint16_t grk::PacketIter::numcomps
private

◆ packetManager

PacketManager* grk::PacketIter::packetManager
private

◆ precinctIndex

uint64_t grk::PacketIter::precinctIndex
private

◆ precinctInfoOPT_

ResPrecinctInfo* grk::PacketIter::precinctInfoOPT_
private

◆ prog

grk_progression grk::PacketIter::prog
private

◆ px0grid_

uint32_t grk::PacketIter::px0grid_
private

◆ py0grid_

uint32_t grk::PacketIter::py0grid_
private

◆ resno

uint8_t grk::PacketIter::resno
private

◆ singleProgression_

bool grk::PacketIter::singleProgression_
private

◆ skippedLeft_

bool grk::PacketIter::skippedLeft_
private

Referenced by next_rpclOPT().

◆ x

uint64_t grk::PacketIter::x
private

◆ y

uint64_t grk::PacketIter::y
private

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