Commit 64c23111 authored by Sebastien Alaiwan's avatar Sebastien Alaiwan
Browse files

Inline function 'read_marker'

Change-Id: I7c06cf9050ebf3412860473ca16915c0fab580e5
parent 2b1ec180
......@@ -772,7 +772,7 @@ static aom_codec_err_t decoder_decode(aom_codec_alg_priv_t *ctx,
// Account for suboptimal termination by the encoder.
while (data_start < data_end) {
const uint8_t marker = read_marker(data_start);
const uint8_t marker = data_start[0];
if (marker) break;
++data_start;
}
......
......@@ -470,7 +470,7 @@ aom_codec_err_t av1_parse_superframe_index(const uint8_t *data, size_t data_sz,
size_t frame_sz_sum = 0;
assert(data_sz);
marker = read_marker(data);
marker = data[0];
*count = 0;
if ((marker & 0xe0) == 0xc0) {
......@@ -484,7 +484,7 @@ aom_codec_err_t av1_parse_superframe_index(const uint8_t *data, size_t data_sz,
if (data_sz < index_sz) return AOM_CODEC_CORRUPT_FRAME;
{
const uint8_t marker2 = read_marker(data + index_sz - 1);
const uint8_t marker2 = data[index_sz - 1];
// This chunk is marked as having a superframe index but doesn't have
// the matching marker byte at the front of the index therefore it's an
......
......@@ -116,10 +116,7 @@ aom_codec_err_t av1_copy_reference_dec(struct AV1Decoder *pbi, int idx,
aom_codec_err_t av1_set_reference_dec(AV1_COMMON *cm, int idx,
YV12_BUFFER_CONFIG *sd);
static INLINE uint8_t read_marker(const uint8_t *data) { return *data; }
// This function is exposed for use in tests, as well as the inlined function
// "read_marker".
// This function is exposed for use in tests
aom_codec_err_t av1_parse_superframe_index(const uint8_t *data, size_t data_sz,
uint32_t sizes[8], int *count,
int *index_size);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment