Lines Matching refs:buffer
39 uint64_t buffer;
84 * switch over to next input buffer
116 vlc->buffer |= (uint64_t)*vlc->data << (24 + vlc->invalid_bits);
123 * fill the bit buffer, so that at least 32 bits are valid
130 /* as long as the buffer needs to be filled */
147 /* enough bytes in buffer, read in a whole dword */
154 vlc->buffer |= value << vlc->invalid_bits;
158 /* buffer is now definitely filled up avoid the loop test */
163 /* not enough bytes left in buffer, read single bytes */
164 vlc->buffer |= (uint64_t)*vlc->data << (24 + vlc->invalid_bits);
172 * initialize vlc structure and start reading from first input buffer
183 vlc->buffer = 0;
200 * number of bits still valid in bit buffer
220 * get num_bits from bit buffer without removing them
226 return vlc->buffer >> (64 - num_bits);
230 * remove num_bits from bit buffer
237 vlc->buffer <<= num_bits;
242 * get num_bits from bit buffer with removing them
251 value = vlc->buffer >> (64 - num_bits);
258 * treat num_bits as signed value and remove them from bit buffer
267 value = ((int64_t)vlc->buffer) >> (64 - num_bits);
294 /* deplete the bit buffer */
347 uint64_t lo = (vlc->buffer & (~0UL >> (pos + num_bits))) << num_bits;
348 uint64_t hi = (vlc->buffer & (~0UL << (64 - pos)));
349 vlc->buffer = lo | hi;
364 vlc->buffer &= ~0L << (vlc->invalid_bits + 32);