#include "src/utils/raw_bit_reader.h"
#include <cassert>
#include <limits>
#include "src/utils/common.h"
#include "src/utils/logging.h"
#if LIBGAV1_ENABLE_LOGGING
#include <cinttypes>
#endif
namespace libgav1 {
namespace {
constexpr int kMaximumLeb128Size = …;
constexpr uint8_t kLeb128ValueByteMask = …;
constexpr uint8_t kLeb128TerminationByteMask = …;
uint8_t Mod8(size_t n) { … }
size_t DivideBy8(size_t n, bool ceil) { … }
}
RawBitReader::RawBitReader(const uint8_t* data, size_t size)
: … { … }
int RawBitReader::ReadBitImpl() { … }
int RawBitReader::ReadBit() { … }
int64_t RawBitReader::ReadLiteral(int num_bits) { … }
bool RawBitReader::ReadInverseSignedLiteral(int num_bits, int* const value) { … }
bool RawBitReader::ReadLittleEndian(int num_bytes, size_t* const value) { … }
bool RawBitReader::ReadUnsignedLeb128(size_t* const value) { … }
bool RawBitReader::ReadUvlc(uint32_t* const value) { … }
bool RawBitReader::AlignToNextByte() { … }
bool RawBitReader::VerifyAndSkipTrailingBits(size_t num_bits) { … }
bool RawBitReader::SkipBytes(size_t num_bytes) { … }
bool RawBitReader::SkipBits(size_t num_bits) { … }
bool RawBitReader::CanReadLiteral(size_t num_bits) const { … }
bool RawBitReader::Finished() const { … }
}