3 #ifndef __C_WRAPPERS_H
\r
4 #define __C_WRAPPERS_H
\r
6 #include "../ICoder.h"
\r
7 #include "../../Common/MyCom.h"
\r
9 struct CCompressProgressWrap
\r
11 ICompressProgress p;
\r
12 ICompressProgressInfo *Progress;
\r
14 CCompressProgressWrap(ICompressProgressInfo *progress);
\r
17 struct CSeqInStreamWrap
\r
20 ISequentialInStream *Stream;
\r
22 CSeqInStreamWrap(ISequentialInStream *stream);
\r
25 struct CSeekInStreamWrap
\r
30 CSeekInStreamWrap(IInStream *stream);
\r
33 struct CSeqOutStreamWrap
\r
36 ISequentialOutStream *Stream;
\r
39 CSeqOutStreamWrap(ISequentialOutStream *stream);
\r
42 HRESULT SResToHRESULT(SRes res);
\r
44 struct CByteInBufWrap
\r
51 ISequentialInStream *Stream;
\r
57 ~CByteInBufWrap() { Free(); }
\r
59 bool Alloc(UInt32 size);
\r
67 UInt64 GetProcessed() const { return Processed + (Cur - Buf); }
\r
68 Byte ReadByteFromNewBlock();
\r
73 return ReadByteFromNewBlock();
\r
77 struct CByteOutBufWrap
\r
84 ISequentialOutStream *Stream;
\r
89 ~CByteOutBufWrap() { Free(); }
\r
91 bool Alloc(size_t size);
\r
99 UInt64 GetProcessed() const { return Processed + (Cur - Buf); }
\r
101 void WriteByte(Byte b)
\r