BitReader{ cache: 0, pos: 0, bits: 0, src, mode }
}
BitReader{ cache: 0, pos: 0, bits: 0, src, mode }
}
/// Reports the current bit position in the bitstream (usually simply the number of bits read so far).
pub fn tell(&self) -> usize {
self.pos * 8 - (self.bits as usize)
/// Reports the current bit position in the bitstream (usually simply the number of bits read so far).
pub fn tell(&self) -> usize {
self.pos * 8 - (self.bits as usize)
pub fn read_s(&mut self, nbits: u8) -> BitReaderResult<i32> {
if nbits == 0 || nbits > 32 { return Err(TooManyBitsRequested) }
if self.bits < nbits {
pub fn read_s(&mut self, nbits: u8) -> BitReaderResult<i32> {
if nbits == 0 || nbits > 32 { return Err(TooManyBitsRequested) }
if self.bits < nbits {