/* * Copyright (c) 2016, Alliance for Open Media. All rights reserved. * * This source code is subject to the terms of the BSD 2 Clause License and * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License * was not distributed with this source code in the LICENSE file, you can * obtain it at www.aomedia.org/license/software. If the Alliance for Open * Media Patent License 1.0 was not distributed with this source code in the * PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
// Stores the location and size of a tile's data in the bitstream. Used for // later identifying identical tiles typedefstruct {
uint8_t *data;
size_t size;
} TileBufferEnc;
typedefstruct { struct aom_write_bit_buffer *saved_wb; // Bit stream buffer writer structure
TileBufferEnc buf; // Structure to hold bitstream buffer and size
uint32_t *total_size; // Size of the bitstream buffer for the tile in bytes
uint8_t *dst; // Base address of tile bitstream buffer
uint8_t *tile_data_curr; // Base address of tile-group bitstream buffer
size_t tile_buf_size; // Available bitstream buffer for the tile in bytes
uint8_t obu_extn_header; // Presence of OBU extension header
uint32_t obu_header_size; // Size of the OBU header int curr_tg_hdr_size; // Size of the obu, tg, frame headers int tile_size_mi; // Tile size in mi units int tile_row; // Number of tile rows int tile_col; // Number of tile columns int is_last_tile_in_tg; // Flag to indicate last tile in a tile-group int new_tg; // Flag to indicate starting of a new tile-group
} PackBSParams;
// Pack bitstream data for pack bitstream multi-threading. typedefstruct { #if CONFIG_MULTITHREAD // Mutex lock used while dispatching jobs.
pthread_mutex_t *mutex_; #endif // Tile order structure of pack bitstream multithreading.
PackBSTileOrder pack_bs_tile_order[MAX_TILES];
// Index of next job to be processed. int next_job_idx; // Initialized to false, set to true by the worker thread that encounters an // error in order to abort the processing of other worker threads. bool pack_bs_mt_exit;
} AV1EncPackBSSync;
/*!\endcond */
// Writes only the OBU Sequence Header payload, and returns the size of the // payload written to 'dst'. This function does not write the OBU header, the // optional extension, or the OBU size to 'dst'.
uint32_t av1_write_sequence_header_obu(const SequenceHeader *seq_params,
uint8_t *const dst, size_t dst_size);
// Writes the OBU header byte, and the OBU header extension byte when both // has_nonzero_operating_point_idc and is_layer_specific_obu are true. // Returns number of bytes written to 'dst'.
uint32_t av1_write_obu_header(AV1LevelParams *const level_params, int *frame_header_count, OBU_TYPE obu_type, bool has_nonzero_operating_point_idc, bool is_layer_specific_obu, int obu_extension,
uint8_t *const dst);
// Encodes obu_payload_size as a leb128 integer and writes it to the dest // buffer. The output must fill the buffer exactly. Returns AOM_CODEC_OK on // success, AOM_CODEC_ERROR on failure. int av1_write_uleb_obu_size(size_t obu_payload_size, uint8_t *dest,
size_t dest_size);
// Pack tile data in the bitstream with tile_group, frame // and OBU header. void av1_pack_tile_info(struct AV1_COMP *const cpi, struct ThreadData *const td,
PackBSParams *const pack_bs_params);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.