⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ebcot_decoder.h

📁 关于视频压缩的jpeg2000压缩算法,C编写
💻 H
📖 第 1 页 / 共 4 页
字号:
    int xref, yref;    int min_band, max_band;    ebcot_packet_band_info_ptr bands;    int included_layers;    int *layer_bytes;    int packet_loss_encountered;    int last_packet_sequence_idx;  } ebcot_packet_info, *ebcot_packet_info_ptr;  /* Holds information specific to a given packet.         `tnum', `component_idx', `level_idx' and `packet_idx'     together specify the coordinates of the packet within the entire     code-stream.         `xref' and `yref' hold the absolute coordinates of the upper left     hand corner of the packet, mapped into the high-resolution reference     grid; these identify the location of the packet in the same coordinate     system as the containing `ebcot_tile' structure's `reference_dims'     coordinates.  The information is used only when constructing spatially     oriented packet progression sequences.         `min_band', `max_band' and `bands' play identical roles to     their namesakes in the `ebcot_band_info' structure, except that     the `bands' array contains `ebcot_packet_band_info' structures     which manage the state of each subband within the scope of the     packets.         `included_layers' indicates the total number of quality layers     which have been included so far while building the packet progression     sequence managed by the `packet_sequence' array in the containing     `ebcot_tile' structure.  Once the packet sequence array has been     constructed, the field takes on a new role, indicating the total     number of layers which have been recovered for this packet from     the codestream so far.         `layer_bytes' is an array with one entry for each quality layer     available in the containing tile.  It is used to store the number of     bytes occupied by each codestream packet (i.e. each quality layer within     the scope of the current packet).         `packet_loss_encountered' is a flag which identifies whether or     not a corrupted codestream packet has been found, i.e. whether or     not this packet scope has been found corrupted in any quality layer     encountered so far.  the significance of corrupted packets is that     the information from later packets (higher quality layer indices)     within the same packet scope should simply be discarded.         `last_packet_sequence_idx' holds the zero-based sequence index of     the last codestream packet which uses this packet scope; it indexes     into the `packet_sequence' array managed by the containing `ebcot_tile'     structure. *//* ========================================================================= *//* ----------------------------- Line Buffering ---------------------------- *//* ========================================================================= *//*****************************************************************************//*                            ebcot_line_buffering                           *//*****************************************************************************/typedef  struct ebcot_line_buffering {    int num_lines;    ebcot_block_info_ptr info;    ifc_int **buffers;  } ebcot_line_buffering, *ebcot_line_buffering_ptr;  /* This structure manages buffering of a row of blocks when data is     requested by the quantizer in lines rather than blocks.         `num_lines' holds the number of lines which have been requested     so far.  Once this reaches the height of a block, the next request for     a line will force the decoding of a new row of blocks and the `num_lines'     counter will be reset.         `info' points to the `ebcot_block_info' entry for the first block in     the row of blocks from which lines are being requested.         `buffers' points to a row of block buffers.  Each block buffer     conforms to the requirements of the `sample_buffer' array described     under the definition of the `block_master' structure.  The buffers     are only allocated in the event that the `pull_line' interface     function is used. *//* ========================================================================= *//* ---------------------------- Subband Structure -------------------------- *//* ========================================================================= *//*****************************************************************************//*                               ebcot_band_info                             *//*****************************************************************************/typedef  struct ebcot_band_info {    int tnum, component_idx, level_idx, band_idx;    int orientation_idx;    canvas_dims dims;    frame_info frame;    int block_rows, block_cols;    std_byte *zc_lut;    int extra_lsbs;    ebcot_line_buffering lines;    block_coding_pass_func pass_funcs[PASSES_PER_BITPLANE];    reverse_roi_ref roi;    int max_roi_boost;    int roi_implicit;    int blocks_wide, blocks_high, total_blocks;    ebcot_block_info_ptr blocks;  } ebcot_band_info, *ebcot_band_info_ptr;  /* This structure describes a single subband within the wavelet     decomposition for a single tile.         `tnum', `component_idx', `level_idx' and `band_idx' identify     the complete coordinates of the subband.         `orientation_idx' holds one of LL_BAND, HL_BAND, LH_BAND or HH_BAND,     depending upon whether the subband's primary orientation corresponds to     low-pass filtering in both directions, high-pass filtering in the     horizontal direction, high-pass filtering in the vertical direction or     high-pass filtering in both directions, respectively.  For Mallat     decompositions, all subbands will have `band_idx' = `orientation_idx'.     This is not true, however, for more complex decompositions in which     the primary subbands in the relevant resolution level are decomposed     further.  This is carefully explained in the master "ifc.h" header     file.         `dims' holds the location and dimensions of the subband within the     relevant tile.         `frame' holds framing information for the subband.         `block_rows' and `block_cols' identify the dimensions of the     actual code-block partition for the subband within the relevant tile.     These are determined from the nominal code-block dimensions for the     entire tile, the frame dimensions mapped into the subband (if they are     to be respected) and the packet partition dimensions mapped into the     subband.         `zc_lut' points to the lookup table to be used in translating     neighbourhood significance information into a coding context for     coding whether a zero sample becomes non-zero or not in a particular     pass; this is called zero-coding.         `extra_lsbs' is the value recovered from the `reverse_info'     object upon initialization.         `lines' holds the state information for the line buffering mechanism     which is activated by calls to the encoder object's `push_line'     interface function.         `pass_funcs' holds pointers to the encoding functions to be used     for each block coding pass in any given bit-plane.         `roi' holds a reference to the ROI object which may modify the     entropy coder's behaviour in particular code-blocks.         `max_roi_boost' holds the maximum boost for any region as returned     by the `reverse_roi__get_max_boost' function.         `roi_implicit' is non-zero if the decoder should be able to     determine the ROI partition within any given block, based only on     the magnitudes of the decoded samples.         `blocks_wide' and `blocks_high' identify the number of code-blocks     which span the width and height of the subband, respectively, within     the current tile, while `total_blocks' holds their product.         `blocks' points to an array containing parameters and state     information for all `total_blocks' code-blocks, arranged in scan-line     order. *//*****************************************************************************//*                              ebcot_level_info                             *//*****************************************************************************/typedef  struct ebcot_level_info {    int tnum, component_idx, level_idx;    canvas_dims dims;    frame_info frame;    int hp_descent;    int min_band;    int max_band;    ebcot_band_info_ptr bands;    int ppx, ppy;    int packets_wide, packets_high, total_packets;    ebcot_packet_info_ptr packets;    int next_packet_idx;  } ebcot_level_info, *ebcot_level_info_ptr;  /* This structure describes a single resolution level within the Wavelet     decomposition for a single image component of a single tile.  The     `ebcot_component_info' structure manages an array of these structures,     with `num_levels'+1 entries, as explained in the comments appearing with     the definition of `ebcot_component_info'.         `tnum', `component_idx' and `level_idx' identify the coordinates of     the resolution level.         `dims' holds the location and dimensions of the relevant tile     at this resolution level.         `frame' holds framing information mapped to the current     resolution level.         `hp_descent' is the value returned by its namesake argument     in the  `forward_info__get_level_info' interface function defined in     "ifc.h".         `min_band' and `max_band' hold the minimum and maximum indices of     the subbands which can be accessed within the resolution level.  It     should be noted that the range may be empty, i.e. `min_band' may     exceed `max_band', in some cases.         `bands' holds information for each subband in the resolution level.     The array contains `max_band'+1 entries, which means that the first     `min_band' entries will never be used; however, this simplifies the     application of the `band_idx' argument supplied to the `push_line' and     `push_block' interface functions.         `ppx' and `ppy' identify the width and height of the packet partition     for this resolution level; specifically, the packet partition width is     equal to 2^{ppx} and its height is equal to 2^{ppy}.  If no packet     partition is used, these quantities will both be negative.         `packets_wide' and `packets_high' identify the number of packets     which span the width and height of the tile within this resolution level,     while `total_packets' holds the product of `packets_wide' and     `packets_high'.  There will often only be one packet in any given     resolution level, which is the original form proposed for the EBCOT     algorithm; multiple packets can be used to improve parsability and/or     coherence in the codestream to reduce resource consumption in specific     applications.         `packets' points to an array of `total_packets' `ebcot_packet_info'     structures which manage the state of each packet.         `next_packet_idx' holds the index of the next packet in this     resolution level to be included in a spatially oriented packet     progression sequence.  It is used only to build these sequences and     has no interpretation at any other point. *//*****************************************************************************//*                            ebcot_component_info                           *//*****************************************************************************/typedef  struct ebcot_component_info {

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -