1 #ifndef APE_UNBITARRAY_H
2 #define APE_UNBITARRAY_H
5 #include "UnBitArrayBase.h"
11 struct RANGE_CODER_STRUCT_DECOMPRESS
13 unsigned int low
; // low end of interval
14 unsigned int range
; // length of interval
15 unsigned int buffer
; // buffer for input/output
19 class CUnBitArray
: public CUnBitArrayBase
22 CUnBitArray(CIO
* pIO
, int nVersion
);
25 uint
DecodeValue(DECODE_VALUE_METHOD DecodeMethod
,
26 int nParam1
= 0, int nParam2
= 0);
28 void GenerateArray(int * pOutputArray
, int nElements
,
29 int nBytesRequired
= -1);
31 int DecodeValueRange(UNBIT_ARRAY_STATE
& BitArrayState
);
33 void FlushState(UNBIT_ARRAY_STATE
& BitArrayState
);
38 void GenerateArrayRange(int * pOutputArray
, int nElements
);
42 int m_nFinalizeCounter
;
44 RANGE_CODER_STRUCT_DECOMPRESS m_RangeCoderInfo
;
46 uint32 m_nRefillBitThreshold
;
49 inline int RangeDecodeFast(int nShift
);
50 inline int RangeDecodeFastWithUpdate(int nShift
);
55 #endif // #ifndef APE_UNBITARRAY_H