OpenJPH Open-source implementation of JPEG2000 Part-15

Loading...
Searching...
No Matches
ojph::local::codeblock Class Reference

`#include <ojph_codeblock.h>`

## Public Member Functions
void | finalize_alloc (codestream *codestream, subband *parent, const size &nominal, const size &cb_size, coded_cb_header *coded_cb, ui32 K_max, int tbx0, ui32 precision, ui32 comp_idx)
void | push (line_buf *line)
void | encode (mem_elastic_allocator *elastic)
void | recreate (const size &cb_size, coded_cb_header *coded_cb)
void | decode ()
void | pull_line (line_buf *line)

## Static Public Member Functions
static void | pre_alloc (codestream *codestream, const size &nominal, ui32 precision)

## Private Types
enum | : ui32 { BUF32 = 4 , BUF64 = 8 }

## Private Attributes
ui32 | precision
union { |
ui32 * buf32 |
ui64 * buf64 |
}; |
size | nominal_size
size | cb_size
ui32 | stride
ui32 | buf_size
subband * | parent
int | line_offset
ui32 | cur_line
float | delta
float | delta_inv
ui32 | K_max
bool | reversible
bool | resilient
bool | stripe_causal
bool | zero_block
union { |
ui32 max_val32 [8] |
ui64 max_val64 [4] |
}; |
coded_cb_header * | coded_cb
codeblock_fun | codeblock_functions

## Friends
struct | precinct

## Detailed Description

Definition at line 65 of file ojph_codeblock.h.

## Member Enumeration Documentation

## ◆ anonymous enum

anonymous enum : ui32
| private

Enumerator
BUF32 |
BUF64 |

Definition at line 68 of file ojph_codeblock.h.

## Member Function Documentation

## ◆ decode()

void ojph::local::codeblock::decode | ( |  | ) |

Definition at line 188 of file ojph_codeblock.cpp.

References BUF32, buf32, BUF64, buf64, cb_size, codeblock_functions, coded_cb, OJPH_ERROR, OJPH_INFO, precision, ojph::local::coded_cb_header::prefix_buf_size, resilient, stride, stripe_causal, and zero_block.

## ◆ encode()

void ojph::local::codeblock::encode | ( | mem_elastic_allocator * | elastic | ) |

Definition at line 140 of file ojph_codeblock.cpp.

References BUF32, buf32, BUF64, buf64, cb_size, codeblock_functions, coded_cb, K_max, max_val32, max_val64, precision, and stride.

## ◆ finalize_alloc()

void ojph::local::codeblock::finalize_alloc | ( | codestream * | codestream,
|  | subband * | parent,
|  | const size & | nominal,
|  | const size & | cb_size,
|  | coded_cb_header * | coded_cb,
|  | ui32 | K_max,
|  | int | tbx0,
|  | ui32 | precision,
|  | ui32 | comp_idx )

Definition at line 72 of file ojph_codeblock.cpp.

References BUF32, buf32, BUF64, buf64, buf_size, ojph::byte_alignment, cb_size, codeblock_functions, coded_cb, cur_line, delta, delta_inv, ojph::local::codestream::get_allocator(), ojph::local::param_cod::get_block_vertical_causality(), ojph::local::codestream::get_coc(), ojph::size::h, ojph::local::codestream::is_resilient(), ojph::local::param_cod::is_reversible(), K_max, line_offset, max_val64, nominal_size, parent, ojph::mem_fixed_allocator::post_alloc_data(), precision, resilient, reversible, stride, stripe_causal, ojph::size::w, and zero_block.

## ◆ pre_alloc()

void ojph::local::codeblock::pre_alloc | ( | codestream * | codestream,
|  | const size & | nominal,
|  | ui32 | precision )
| static

Definition at line 56 of file ojph_codeblock.cpp.

References ojph::byte_alignment, ojph::local::codestream::get_allocator(), ojph::size::h, ojph::mem_fixed_allocator::pre_alloc_data(), precision, stride, and ojph::size::w.

Referenced by ojph::local::subband::pre_alloc().

## ◆ pull_line()

void ojph::local::codeblock::pull_line | ( | line_buf * | line | ) |

Definition at line 228 of file ojph_codeblock.cpp.

References BUF32, buf32, BUF64, buf64, cb_size, codeblock_functions, cur_line, delta, ojph::line_buf::flags, ojph::line_buf::i32, ojph::line_buf::i64, K_max, ojph::line_buf::LFT_32BIT, ojph::line_buf::LFT_64BIT, line_offset, precision, stride, and zero_block.

## ◆ push()

void ojph::local::codeblock::push | ( | line_buf * | line | ) |

Definition at line 115 of file ojph_codeblock.cpp.

References BUF32, buf32, BUF64, buf64, cb_size, codeblock_functions, cur_line, delta_inv, ojph::line_buf::flags, ojph::line_buf::i32, ojph::line_buf::i64, K_max, ojph::line_buf::LFT_32BIT, ojph::line_buf::LFT_64BIT, line_offset, max_val32, max_val64, precision, and stride.

## ◆ recreate()

void ojph::local::codeblock::recreate | ( | const size & | cb_size,
|  | coded_cb_header * | coded_cb )

Definition at line 176 of file ojph_codeblock.cpp.

References buf_size, cb_size, coded_cb, cur_line, max_val64, stride, and zero_block.

## Friends And Related Symbol Documentation

## ◆ precinct

friend struct precinct
| friend

Definition at line 67 of file ojph_codeblock.h.

References precinct.

Referenced by precinct.

## Member Data Documentation

## ◆ [union]

union { ... } ojph::local::codeblock

## ◆ [union]

union { ... } ojph::local::codeblock

## ◆ buf32

ui32* ojph::local::codeblock::buf32

Definition at line 90 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pull_line(), and push().

## ◆ buf64

ui64* ojph::local::codeblock::buf64

Definition at line 91 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pull_line(), and push().

## ◆ buf_size

ui32 ojph::local::codeblock::buf_size
| private

Definition at line 96 of file ojph_codeblock.h.

Referenced by finalize_alloc(), and recreate().

## ◆ cb_size

size ojph::local::codeblock::cb_size
| private

Definition at line 94 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pull_line(), push(), and recreate().

## ◆ codeblock_functions

codeblock_fun ojph::local::codeblock::codeblock_functions
| private

Definition at line 111 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pull_line(), and push().

## ◆ coded_cb

coded_cb_header* ojph::local::codeblock::coded_cb
| private

Definition at line 110 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), and recreate().

## ◆ cur_line

ui32 ojph::local::codeblock::cur_line
| private

Definition at line 99 of file ojph_codeblock.h.

Referenced by finalize_alloc(), pull_line(), push(), and recreate().

## ◆ delta

float ojph::local::codeblock::delta
| private

Definition at line 100 of file ojph_codeblock.h.

Referenced by finalize_alloc(), and pull_line().

## ◆ delta_inv

float ojph::local::codeblock::delta_inv
| private

Definition at line 100 of file ojph_codeblock.h.

Referenced by finalize_alloc(), and push().

## ◆ K_max

ui32 ojph::local::codeblock::K_max
| private

Definition at line 101 of file ojph_codeblock.h.

Referenced by encode(), finalize_alloc(), pull_line(), and push().

## ◆ line_offset

int ojph::local::codeblock::line_offset
| private

Definition at line 98 of file ojph_codeblock.h.

Referenced by finalize_alloc(), pull_line(), and push().

## ◆ max_val32

ui32 ojph::local::codeblock::max_val32[8]

Definition at line 107 of file ojph_codeblock.h.

Referenced by encode(), and push().

## ◆ max_val64

ui64 ojph::local::codeblock::max_val64[4]

Definition at line 108 of file ojph_codeblock.h.

Referenced by encode(), finalize_alloc(), push(), and recreate().

## ◆ nominal_size

size ojph::local::codeblock::nominal_size
| private

Definition at line 93 of file ojph_codeblock.h.

Referenced by finalize_alloc().

## ◆ parent

subband* ojph::local::codeblock::parent
| private

Definition at line 97 of file ojph_codeblock.h.

Referenced by finalize_alloc().

## ◆ precision

ui32 ojph::local::codeblock::precision
| private

Definition at line 88 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pre_alloc(), pull_line(), and push().

## ◆ resilient

bool ojph::local::codeblock::resilient
| private

Definition at line 103 of file ojph_codeblock.h.

Referenced by decode(), and finalize_alloc().

## ◆ reversible

bool ojph::local::codeblock::reversible
| private

Definition at line 102 of file ojph_codeblock.h.

Referenced by finalize_alloc().

## ◆ stride

ui32 ojph::local::codeblock::stride
| private

Definition at line 95 of file ojph_codeblock.h.

Referenced by decode(), encode(), finalize_alloc(), pre_alloc(), pull_line(), push(), and recreate().

## ◆ stripe_causal

bool ojph::local::codeblock::stripe_causal
| private

Definition at line 104 of file ojph_codeblock.h.

Referenced by decode(), and finalize_alloc().

## ◆ zero_block

bool ojph::local::codeblock::zero_block
| private

Definition at line 105 of file ojph_codeblock.h.

Referenced by decode(), finalize_alloc(), pull_line(), and recreate().

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

- /build/openjph/src/OpenJPH/src/core/codestream/ojph_codeblock.h
- /build/openjph/src/OpenJPH/src/core/codestream/ojph_codeblock.cpp