bitstream.h

来自「AAC音频解码算法程序」· C头文件 代码 · 共 41 行

H
41
字号
#ifndef _bitstream_h_#define _bitstream_h_#ifndef min#define min(a,b) ( (a) < (b) ? (a) : (b) )#endif#ifndef max#define max(a,b) ( (a) > (b) ? (a) : (b) )#endiftypedef struct _bitstream{  unsigned char *data;		/* data bits */  long numBit;			/* number of bits in buffer */  long size;			/* buffer size in bits */  long currentBit;		/* current bit position in bit stream */  long numByte;			/* number of bytes read/written (only file) */} BsBitStream;BsBitStream *BsOpenWrite(int size);void BsClose(BsBitStream *bs);long BsBufferNumBit (BsBitStream *bs);int BsWriteByte (BsBitStream *stream,				 unsigned long data,				 int numBit);int BsPutBit (BsBitStream *stream,			  unsigned long data,			  int numBit);/* ByteAlign(...), used to byte align bitstream */int ByteAlign(BsBitStream* ptrBs);#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?