live
Public Member Functions | Private Attributes
BitVector Class Reference

#include <BitVector.hh>

Public Member Functions

 BitVector (unsigned char *baseBytePtr, unsigned baseBitOffset, unsigned totNumBits)
 
void setup (unsigned char *baseBytePtr, unsigned baseBitOffset, unsigned totNumBits)
 
void putBits (unsigned from, unsigned numBits)
 
void put1Bit (unsigned bit)
 
unsigned getBits (unsigned numBits)
 
unsigned get1Bit ()
 
Boolean get1BitBoolean ()
 
void skipBits (unsigned numBits)
 
unsigned curBitIndex () const
 
unsigned totNumBits () const
 
unsigned numBitsRemaining () const
 
unsigned get_expGolomb ()
 

Private Attributes

unsigned char * fBaseBytePtr
 
unsigned fBaseBitOffset
 
unsigned fTotNumBits
 
unsigned fCurBitIndex
 

Detailed Description

Definition at line 28 of file BitVector.hh.

Constructor & Destructor Documentation

BitVector::BitVector ( unsigned char *  baseBytePtr,
unsigned  baseBitOffset,
unsigned  totNumBits 
)

Member Function Documentation

unsigned BitVector::curBitIndex ( ) const
inline

Definition at line 47 of file BitVector.hh.

References fCurBitIndex.

47 { return fCurBitIndex; }
unsigned fCurBitIndex
Definition: BitVector.hh:58
unsigned BitVector::get1Bit ( )
Boolean BitVector::get1BitBoolean ( )
inline

Definition at line 43 of file BitVector.hh.

References get1Bit().

43 { return get1Bit() != 0; }
unsigned get1Bit()
unsigned BitVector::get_expGolomb ( )
unsigned BitVector::getBits ( unsigned  numBits)

Referenced by MP3FrameParams::getBits().

unsigned BitVector::numBitsRemaining ( ) const
inline

Definition at line 49 of file BitVector.hh.

References fCurBitIndex, and fTotNumBits.

49 { return fTotNumBits - fCurBitIndex; }
unsigned fCurBitIndex
Definition: BitVector.hh:58
unsigned fTotNumBits
Definition: BitVector.hh:57
void BitVector::put1Bit ( unsigned  bit)
void BitVector::putBits ( unsigned  from,
unsigned  numBits 
)
void BitVector::setup ( unsigned char *  baseBytePtr,
unsigned  baseBitOffset,
unsigned  totNumBits 
)
void BitVector::skipBits ( unsigned  numBits)
unsigned BitVector::totNumBits ( ) const
inline

Definition at line 48 of file BitVector.hh.

References fTotNumBits.

48 { return fTotNumBits; }
unsigned fTotNumBits
Definition: BitVector.hh:57

Field Documentation

unsigned BitVector::fBaseBitOffset
private

Definition at line 56 of file BitVector.hh.

unsigned char* BitVector::fBaseBytePtr
private

Definition at line 55 of file BitVector.hh.

unsigned BitVector::fCurBitIndex
private

Definition at line 58 of file BitVector.hh.

Referenced by curBitIndex(), and numBitsRemaining().

unsigned BitVector::fTotNumBits
private

Definition at line 57 of file BitVector.hh.

Referenced by numBitsRemaining(), and totNumBits().


The documentation for this class was generated from the following file: