grk::DecompressCodeblock Struct Reference

`#include <Codeblock.h>`

Inheritance diagram for grk::DecompressCodeblock:

## Public Member Functions

| DecompressCodeblock (uint16_t numLayers)
virtual | ~DecompressCodeblock ()
Segment * | getSegment (uint32_t segmentIndex)
bool | init ()
uint32_t | getNumSegments (void)
Segment * | getCurrentSegment (void)
Segment * | nextSegment (void)
void | cleanUpSegBuffers ()
size_t | getSegBuffersLen ()
bool | copyToContiguousBuffer (uint8_t *buffer)
void | release (void)
Public Member Functions inherited from grk::Codeblock
| Codeblock (uint16_t numLayers)
virtual | ~Codeblock ()
| Codeblock (const Codeblock &rhs)
Codeblock & | operator= (const Codeblock &rhs)
void | setRect (grk_rect32 r)
uint8_t | getNumPassesInPacket (uint16_t layno)
void | setNumPassesInPacket (uint16_t layno, uint8_t passes)
void | incNumPassesInPacket (uint16_t layno, uint8_t delta)
Public Member Functions inherited from grk::grk_buf2d< int32_t, AllocatorAligned >
| grk_buf2d (int32_t *buffer, bool ownsData, uint32_t w, uint32_t strd, uint32_t h)
| grk_buf2d (uint32_t w, uint32_t h)
| grk_buf2d (const grk_rect32 *b)
| grk_buf2d (const grk_rect32 &b)
| grk_buf2d (const grk_rect32 &b, bool useOrigin)
| grk_buf2d (void)
| grk_buf2d (const grk_buf2d &rhs)
grk_buf2d_simple< int32_t > | simple (void) const
grk_buf2d_simple< float > | simpleF (void) const
grk_buf2d & | operator= (const grk_buf2d &rhs)
grk_buf2d & | operator= (const grk_buf2d *rhs)
virtual | ~grk_buf2d ()=default
bool | alloc2d (bool clear)
void | attach (int32_t *buffer, uint32_t strd)
void | attach (grk_buf2d &rhs, uint32_t x, uint32_t y)
void | attach (grk_buf2d &rhs)
void | attach (grk_buf2d *rhs, uint32_t x, uint32_t y)
void | attach (grk_buf2d *rhs)
void | acquire (int32_t *buffer, uint32_t strd)
void | transfer (int32_t **buffer, uint32_t *strd)
bool | isWindowValid (grk_rect32 win)
| Returns whether window bounds are valid (non empty and within buffer bounds)
void | copyFrom (const grk_buf2d &src, F filter)
void | copyFrom (const grk_buf2d *src, F filter)
void | copyFrom (const grk_buf2d &src)
int32_t * | getBuffer (void) const
int32_t * | address (uint32_t x, uint32_t y)
Public Member Functions inherited from grk::grk_rect< uint32_t >
| grk_rect (uint32_t origin_x0, uint32_t origin_y0, uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)
| grk_rect (uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)
| grk_rect (const grk_rect &rhs)
| grk_rect (const grk_rect *rhs)
| grk_rect (void)
virtual | ~grk_rect ()=default
grk_rect< uint32_t > & | setOrigin (uint32_t origx, uint32_t origy, bool absolute)
grk_rect< uint32_t > & | setOrigin (grk_rect< uint32_t > &rhs, bool absolute)
grk_rect< uint32_t > & | setOrigin (grk_rect< uint32_t > *rhs, bool absolute)
grk_rect< uint32_t > & | toRelative (void)
grk_rect< uint32_t > & | toAbsolute (void)
virtual void | print (void) const
std::string | boundsString () const
bool | valid (void) const
bool | empty (void) const
bool | contains (grk_pt< uint32_t > pt)
bool | contains (uint32_t x, uint32_t y)
grk_rect< uint32_t > & | operator= (const grk_rect< uint32_t > &rhs)
grk_rect< uint32_t > & | operator= (const grk_rect< uint32_t > *rhs)
bool | operator== (const grk_rect< uint32_t > &rhs) const
void | setRect (grk_rect< uint32_t > *rhs)
void | setRect (grk_rect< uint32_t > rhs)
grk_rect< uint32_t > | scaleDownCeil (uint32_t den) const
grk_rect< uint32_t > | scaleDownCeil (uint64_t denx, uint64_t deny) const
grk_rect< uint32_t > | scale (uint32_t scalex, uint32_t scaley) const
grk_rect< uint32_t > | scaleDown (uint64_t denx, uint64_t deny) const
grk_rect< uint32_t > | scaleDownPow2 (uint32_t powx, uint32_t powy) const
grk_rect< uint32_t > | scaleDownPow2 (grk_pt< uint32_t > pow) const
grk_rect< uint32_t > | scaleDownCeilPow2 (uint32_t power) const
grk_rect< uint32_t > | scaleDownCeilPow2 (uint32_t powx, uint32_t powy) const
grk_rect< uint32_t > | intersection (const grk_rect< uint32_t > rhs) const
grk_rect< uint32_t > | intersection (const grk_rect< uint32_t > *rhs) const
bool | isContainedIn (const grk_rect< uint32_t > rhs) const
grk_rect< uint32_t > | clip (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | clip (const grk_rect< uint32_t > &rhs) const
grk_rect< uint32_t > & | clip_IN_PLACE (const grk_rect< uint32_t > &rhs)
bool | nonEmptyIntersection (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | rectUnion (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | rectUnion (const grk_rect< uint32_t > &rhs) const
uint64_t | area (void) const
uint32_t | width () const
uint32_t | height () const
grk_line< uint32_t > | dimX () const
grk_line< uint32_t > | dimY () const
grk_rect< uint32_t > | pan (int64_t x, int64_t y) const
grk_rect< uint32_t > & | pan_IN_PLACE (int64_t x, int64_t y)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary, uint32_t maxX, uint32_t maxY)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy, uint32_t maxX, uint32_t maxY)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary, grk_rect< uint32_t > bounds)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy, grk_rect< uint32_t > bounds)
uint32_t | parityX (void) const
uint32_t | parityY (void) const
Public Member Functions inherited from grk::ICacheable
| ICacheable ()
virtual | ~ICacheable ()=default
bool | isOpen (void)
bool | isClosed (void)
bool | isError (void)
void | setCacheState (GrkCacheState state)

## Public Attributes

std::vector< grk_buf8 * > | seg_buffers
Public Attributes inherited from grk::Codeblock
grk_buf8 | compressedStream
uint8_t | numbps
uint8_t | numlenbits
Public Attributes inherited from grk::grk_buf2d< int32_t, AllocatorAligned >
uint32_t | stride
Public Attributes inherited from grk::grk_rect< uint32_t >
bool | absoluteCoordinates
uint32_t | origin_x0
uint32_t | origin_y0
uint32_t | x0
uint32_t | y0
uint32_t | x1
uint32_t | y1

## Private Attributes

Segment * | segs
uint32_t | numSegments
uint32_t | numSegmentsAllocated

## Additional Inherited Members

Protected Member Functions inherited from grk::grk_buf< T, A >
| grk_buf (T *buffer, size_t off, size_t length, bool ownsData)
| grk_buf (T *buffer, size_t length)
| grk_buf ()
| grk_buf (T *buffer, size_t length, bool ownsData)
virtual | ~grk_buf ()
| grk_buf (const grk_buf &rhs)
grk_buf & | operator= (const grk_buf &rhs)
grk_buf & | operator= (const grk_buf *rhs)
bool | canRead (void)
T | read (void)
bool | write (T val)
bool | write (T *b, size_t size)
virtual bool | alloc (size_t length)
virtual void | dealloc ()
void | attach (T *buffer)
void | acquire (T *buffer)
void | transfer (T **buffer)
size_t | remainingLength (void)
void | incrementOffset (ptrdiff_t off)
T * | currPtr (void) const
Protected Member Functions inherited from grk::grk_rect< uint32_t >
| grk_rect (uint32_t origin_x0, uint32_t origin_y0, uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)
| grk_rect (uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)
| grk_rect (const grk_rect &rhs)
| grk_rect (const grk_rect *rhs)
| grk_rect (void)
virtual | ~grk_rect ()=default
grk_rect< uint32_t > & | setOrigin (uint32_t origx, uint32_t origy, bool absolute)
grk_rect< uint32_t > & | setOrigin (grk_rect< uint32_t > &rhs, bool absolute)
grk_rect< uint32_t > & | setOrigin (grk_rect< uint32_t > *rhs, bool absolute)
grk_rect< uint32_t > & | toRelative (void)
grk_rect< uint32_t > & | toAbsolute (void)
virtual void | print (void) const
std::string | boundsString () const
bool | valid (void) const
bool | empty (void) const
bool | contains (grk_pt< uint32_t > pt)
bool | contains (uint32_t x, uint32_t y)
grk_rect< uint32_t > & | operator= (const grk_rect< uint32_t > &rhs)
grk_rect< uint32_t > & | operator= (const grk_rect< uint32_t > *rhs)
bool | operator== (const grk_rect< uint32_t > &rhs) const
void | setRect (grk_rect< uint32_t > *rhs)
void | setRect (grk_rect< uint32_t > rhs)
grk_rect< uint32_t > | scaleDownCeil (uint32_t den) const
grk_rect< uint32_t > | scaleDownCeil (uint64_t denx, uint64_t deny) const
grk_rect< uint32_t > | scale (uint32_t scalex, uint32_t scaley) const
grk_rect< uint32_t > | scaleDown (uint64_t denx, uint64_t deny) const
grk_rect< uint32_t > | scaleDownPow2 (uint32_t powx, uint32_t powy) const
grk_rect< uint32_t > | scaleDownPow2 (grk_pt< uint32_t > pow) const
grk_rect< uint32_t > | scaleDownCeilPow2 (uint32_t power) const
grk_rect< uint32_t > | scaleDownCeilPow2 (uint32_t powx, uint32_t powy) const
grk_rect< uint32_t > | intersection (const grk_rect< uint32_t > rhs) const
grk_rect< uint32_t > | intersection (const grk_rect< uint32_t > *rhs) const
bool | isContainedIn (const grk_rect< uint32_t > rhs) const
grk_rect< uint32_t > | clip (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | clip (const grk_rect< uint32_t > &rhs) const
grk_rect< uint32_t > & | clip_IN_PLACE (const grk_rect< uint32_t > &rhs)
bool | nonEmptyIntersection (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | rectUnion (const grk_rect< uint32_t > *rhs) const
grk_rect< uint32_t > | rectUnion (const grk_rect< uint32_t > &rhs) const
uint64_t | area (void) const
uint32_t | width () const
uint32_t | height () const
grk_line< uint32_t > | dimX () const
grk_line< uint32_t > | dimY () const
grk_rect< uint32_t > | pan (int64_t x, int64_t y) const
grk_rect< uint32_t > & | pan_IN_PLACE (int64_t x, int64_t y)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary, uint32_t maxX, uint32_t maxY)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy, uint32_t maxX, uint32_t maxY)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundary, grk_rect< uint32_t > bounds)
grk_rect< uint32_t > & | grow_IN_PLACE (uint32_t boundaryx, uint32_t boundaryy, grk_rect< uint32_t > bounds)
uint32_t | parityX (void) const
uint32_t | parityY (void) const
Protected Attributes inherited from grk::Codeblock
std::vector< uint8_t > | numPassesInPacket
Protected Attributes inherited from grk::grk_buf< T, A >
T * | buf
size_t | offset
size_t | len
bool | owns_data
Protected Attributes inherited from grk::grk_rect< uint32_t >
bool | absoluteCoordinates
uint32_t | origin_x0
uint32_t | origin_y0
uint32_t | x0
uint32_t | y0
uint32_t | x1
uint32_t | y1

## Constructor & Destructor Documentation

## DecompressCodeblock()

grk::DecompressCodeblock::DecompressCodeblock | ( | uint16_t | numLayers | ) |

inline

## ~DecompressCodeblock()

virtual grk::DecompressCodeblock::~DecompressCodeblock | ( |  | ) |

inline virtual

References release().

## Member Function Documentation

## cleanUpSegBuffers()

void grk::DecompressCodeblock::cleanUpSegBuffers | ( |  | ) |

inline

References grk::grk_read(), numSegments, and seg_buffers.

Referenced by release().

## copyToContiguousBuffer()

bool grk::DecompressCodeblock::copyToContiguousBuffer | ( | uint8_t * | buffer | ) |

inline

References grk::grk_buf< T, A >::buf, grk::grk_read(), grk::grk_buf< T, A >::offset, and seg_buffers.

## getCurrentSegment()

Segment * grk::DecompressCodeblock::getCurrentSegment | ( | void |  | ) |

inline

References getSegment(), and numSegments.

Referenced by nextSegment(), and grk::PacketParser::readData().

## getNumSegments()

uint32_t grk::DecompressCodeblock::getNumSegments | ( | void |  | ) |

inline

References numSegments.

Referenced by grk::T1::decompress_cblk().

## getSegBuffersLen()

size_t grk::DecompressCodeblock::getSegBuffersLen | ( |  | ) |

inline

References grk::grk_read(), and seg_buffers.

## getSegment()

Segment * grk::DecompressCodeblock::getSegment | ( | uint32_t | segmentIndex | ) |

inline

References grk::grk_read(), numSegmentsAllocated, and segs.

Referenced by grk::T1::decompress_cblk(), getCurrentSegment(), and grk::PacketParser::initSegment().

## init()

bool grk::DecompressCodeblock::init | ( |  | ) |

inline

## nextSegment()

Segment * grk::DecompressCodeblock::nextSegment | ( | void |  | ) |

inline

References getCurrentSegment(), and numSegments.

## release()

void grk::DecompressCodeblock::release | ( | void |  | ) |

inline

References cleanUpSegBuffers(), grk::grk_buf< T, A >::dealloc(), and segs.

Referenced by ~DecompressCodeblock().

## Member Data Documentation

## numSegments

uint32_t grk::DecompressCodeblock::numSegments

private

Referenced by cleanUpSegBuffers(), getCurrentSegment(), getNumSegments(), and nextSegment().

## numSegmentsAllocated

uint32_t grk::DecompressCodeblock::numSegmentsAllocated

private

Referenced by getSegment().

## seg_buffers

std::vector<grk_buf8*> grk::DecompressCodeblock::seg_buffers

Referenced by cleanUpSegBuffers(), copyToContiguousBuffer(), and getSegBuffersLen().

## segs

Segment* grk::DecompressCodeblock::segs

private

Referenced by getSegment(), and release().

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

- Codeblock.h