MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / decode_skip_count

Function decode_skip_count

libavcodec/escape124.c:118–138  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

116}
117
118static unsigned decode_skip_count(GetBitContext* gb)
119{
120 unsigned value;
121 // This function reads a maximum of 23 bits,
122 // which is within the padding space
123 if (!can_safely_read(gb, 1))
124 return -1;
125 value = get_bits1(gb);
126 if (!value)
127 return value;
128
129 value += get_bits(gb, 3);
130 if (value != (1 + ((1 << 3) - 1)))
131 return value;
132
133 value += get_bits(gb, 7);
134 if (value != (1 + ((1 << 3) - 1)) + ((1 << 7) - 1))
135 return value;
136
137 return value + get_bits(gb, 12);
138}
139
140static MacroBlock decode_macroblock(Escape124Context* s, GetBitContext* gb,
141 int* codebook_index, int superblock_index)

Callers 1

escape124_decode_frameFunction · 0.85

Calls 3

can_safely_readFunction · 0.85
get_bits1Function · 0.85
get_bitsFunction · 0.85

Tested by

no test coverage detected