Grok  7.6.6
Public Member Functions | Public Attributes | List of all members
grk::CompressCodeblock Struct Reference

#include <T1Structs.h>

Inheritance diagram for grk::CompressCodeblock:
grk::Codeblock grk::grk_rectangle< uint32_t >

Public Member Functions

 CompressCodeblock ()
 
 ~CompressCodeblock ()
 
 CompressCodeblock (const CompressCodeblock &rhs)
 
CompressCodeblockoperator= (const CompressCodeblock &other)
 
void clear () override
 
bool alloc ()
 
bool alloc_data (size_t nominalBlockSize)
 Allocates data memory for an compressing code block. More...
 
void cleanup ()
 
- Public Member Functions inherited from grk::Codeblock
 Codeblock (const Codeblock &rhs)
 
 Codeblock ()
 
Codeblockoperator= (const Codeblock &other)
 
virtual ~Codeblock ()
 
- Public Member Functions inherited from grk::grk_rectangle< uint32_t >
 grk_rectangle (uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)
 
 grk_rectangle (const grk_rectangle &rhs)
 
 grk_rectangle (void)
 
void print (void) const
 
bool is_valid (void) const
 
bool non_empty (void) const
 
bool contains (grk_point< uint32_t > pt)
 
grk_rectangle< uint32_t > & operator= (const grk_rectangle< uint32_t > &rhs)
 
bool operator== (const grk_rectangle< uint32_t > &rhs) const
 
void set_rect (grk_rectangle< uint32_t > *rhs)
 
void set_rect (grk_rectangle< uint32_t > rhs)
 
grk_rectangle< uint32_t > rectceildivpow2 (uint32_t power) const
 
grk_rectangle< uint32_t > rectceildiv (uint32_t den) const
 
grk_rectangle< uint32_t > rectceildiv (uint32_t denx, uint32_t deny) const
 
grk_rectangle< uint32_t > intersection (const grk_rectangle< uint32_t > rhs) const
 
grk_rectangle< uint32_t > intersection (const grk_rectangle< uint32_t > *rhs) const
 
bool isContainedIn (const grk_rectangle< uint32_t > rhs) const
 
void clip (const grk_rectangle< uint32_t > *rhs)
 
grk_rectangle< uint32_t > rect_union (const grk_rectangle< uint32_t > *rhs) const
 
grk_rectangle< uint32_t > rect_union (const grk_rectangle< uint32_t > &rhs) const
 
uint64_t area (void) const
 
uint32_t width () const
 
uint32_t height () const
 
grk_line< uint32_t > dimX ()
 
grk_line< uint32_t > dimY ()
 
grk_rectangle< uint32_t > pan (int64_t x, int64_t y) const
 
void pan_inplace (int64_t x, int64_t y)
 
grk_rectangle< uint32_t > & grow (uint32_t boundary)
 
grk_rectangle< uint32_t > & grow (uint32_t boundaryx, uint32_t boundaryy)
 
grk_rectangle< uint32_t > & grow (uint32_t boundary, uint32_t maxX, uint32_t maxY)
 
grk_rectangle< uint32_t > & grow (uint32_t boundaryx, uint32_t boundaryy, uint32_t maxX, uint32_t maxY)
 
grk_rectangle< uint32_t > & grow (uint32_t boundary, grk_rectangle< uint32_t > bounds)
 
grk_rectangle< uint32_t > & grow (uint32_t boundaryx, uint32_t boundaryy, grk_rectangle< uint32_t > bounds)
 

Public Attributes

uint8_t * paddedCompressedStream
 
Layerlayers
 
CodePasspasses
 
uint32_t numPassesInPreviousPackets
 
uint32_t numPassesTotal
 
uint32_t * contextStream
 
- Public Attributes inherited from grk::Codeblock
grk_buf compressedStream
 
uint32_t numbps
 
uint32_t numlenbits
 
uint32_t numPassesInPacket
 
- Public Attributes inherited from grk::grk_rectangle< uint32_t >
uint32_t x0
 
uint32_t y0
 
uint32_t x1
 
uint32_t y1
 

Constructor & Destructor Documentation

◆ CompressCodeblock() [1/2]

grk::CompressCodeblock::CompressCodeblock ( )

◆ ~CompressCodeblock()

grk::CompressCodeblock::~CompressCodeblock ( )

References cleanup().

◆ CompressCodeblock() [2/2]

grk::CompressCodeblock::CompressCodeblock ( const CompressCodeblock rhs)

Member Function Documentation

◆ alloc()

bool grk::CompressCodeblock::alloc ( )

References grk::grk_calloc(), layers, and passes.

◆ alloc_data()

bool grk::CompressCodeblock::alloc_data ( size_t  nominalBlockSize)

Allocates data memory for an compressing code block.

We actually allocate 2 more bytes than specified, and then offset data by +2. This is done so that we can safely initialize the MQ coder pointer to data-1, without risk of accessing uninitialized memory.

References grk::grk_buffer< T >::buf, grk::Codeblock::compressedStream, grk_cblk_enc_compressed_data_pad_left, grk::grk_buffer< T >::len, grk::grk_buffer< T >::owns_data, and paddedCompressedStream.

◆ cleanup()

void grk::CompressCodeblock::cleanup ( )

◆ clear()

void grk::CompressCodeblock::clear ( )
overridevirtual

Reimplemented from grk::Codeblock.

References grk::Codeblock::clear(), contextStream, layers, and passes.

◆ operator=()

CompressCodeblock & grk::CompressCodeblock::operator= ( const CompressCodeblock other)

Member Data Documentation

◆ contextStream

uint32_t* grk::CompressCodeblock::contextStream

Referenced by clear(), and operator=().

◆ layers

Layer* grk::CompressCodeblock::layers

Referenced by alloc(), cleanup(), clear(), and operator=().

◆ numPassesInPreviousPackets

uint32_t grk::CompressCodeblock::numPassesInPreviousPackets

◆ numPassesTotal

uint32_t grk::CompressCodeblock::numPassesTotal

◆ paddedCompressedStream

uint8_t* grk::CompressCodeblock::paddedCompressedStream

◆ passes

CodePass* grk::CompressCodeblock::passes

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