8 #define CODER_INTERFACE(i, x) DECL_INTERFACE(i, 4, x)
10 CODER_INTERFACE(ICompressProgressInfo, 0x04)
12 STDMETHOD(SetRatioInfo)(const UInt64 *inSize, const UInt64 *outSize) PURE;
15 CODER_INTERFACE(ICompressCoder, 0x05)
17 STDMETHOD(Code)(ISequentialInStream *inStream,
18 ISequentialOutStream *outStream,
20 const UInt64 *outSize,
21 ICompressProgressInfo *progress) PURE;
24 CODER_INTERFACE(ICompressCoder2, 0x18)
26 STDMETHOD(Code)(ISequentialInStream **inStreams,
27 const UInt64 **inSizes,
29 ISequentialOutStream **outStreams,
30 const UInt64 **outSizes,
32 ICompressProgressInfo *progress) PURE;
35 namespace NCoderPropID
39 kDictionarySize = 0x400,
42 kPosStateBits = 0x440,
45 kNumFastBytes = 0x450,
56 CODER_INTERFACE(ICompressSetCoderProperties, 0x20)
58 STDMETHOD(SetCoderProperties)(const PROPID *propIDs,
59 const PROPVARIANT *properties, UInt32 numProperties) PURE;
63 CODER_INTERFACE(ICompressSetCoderProperties, 0x21)
65 STDMETHOD(SetDecoderProperties)(ISequentialInStream *inStream) PURE;
69 CODER_INTERFACE(ICompressSetDecoderProperties2, 0x22)
71 STDMETHOD(SetDecoderProperties2)(const Byte *data, UInt32 size) PURE;
74 CODER_INTERFACE(ICompressWriteCoderProperties, 0x23)
76 STDMETHOD(WriteCoderProperties)(ISequentialOutStream *outStreams) PURE;
79 CODER_INTERFACE(ICompressGetInStreamProcessedSize, 0x24)
81 STDMETHOD(GetInStreamProcessedSize)(UInt64 *value) PURE;
84 CODER_INTERFACE(ICompressSetCoderMt, 0x25)
86 STDMETHOD(SetNumberOfThreads)(UInt32 numThreads) PURE;
89 CODER_INTERFACE(ICompressGetSubStreamSize, 0x30)
91 STDMETHOD(GetSubStreamSize)(UInt64 subStream, UInt64 *value) PURE;
94 CODER_INTERFACE(ICompressSetInStream, 0x31)
96 STDMETHOD(SetInStream)(ISequentialInStream *inStream) PURE;
97 STDMETHOD(ReleaseInStream)() PURE;
100 CODER_INTERFACE(ICompressSetOutStream, 0x32)
102 STDMETHOD(SetOutStream)(ISequentialOutStream *outStream) PURE;
103 STDMETHOD(ReleaseOutStream)() PURE;
106 CODER_INTERFACE(ICompressSetInStreamSize, 0x33)
108 STDMETHOD(SetInStreamSize)(const UInt64 *inSize) PURE;
111 CODER_INTERFACE(ICompressSetOutStreamSize, 0x34)
113 STDMETHOD(SetOutStreamSize)(const UInt64 *outSize) PURE;
116 CODER_INTERFACE(ICompressFilter, 0x40)
118 STDMETHOD(Init)() PURE;
119 STDMETHOD_(UInt32, Filter)(Byte *data, UInt32 size) PURE;
120 // Filter return outSize (UInt32)
121 // if (outSize <= size): Filter have converted outSize bytes
122 // if (outSize > size): Filter have not converted anything.
123 // and it needs at least outSize bytes to convert one block
124 // (it's for crypto block algorithms).
127 CODER_INTERFACE(ICompressCodecsInfo, 0x60)
129 STDMETHOD(GetNumberOfMethods)(UInt32 *numMethods) PURE;
130 STDMETHOD(GetProperty)(UInt32 index, PROPID propID, PROPVARIANT *value) PURE;
131 STDMETHOD(CreateDecoder)(UInt32 index, const GUID *iid, void **coder) PURE;
132 STDMETHOD(CreateEncoder)(UInt32 index, const GUID *iid, void **coder) PURE;
134 CODER_INTERFACE(ISetCompressCodecsInfo, 0x61)
136 STDMETHOD(SetCompressCodecsInfo)(ICompressCodecsInfo *compressCodecsInfo) PURE;
139 CODER_INTERFACE(ICryptoProperties, 0x80)
141 STDMETHOD(SetKey)(const Byte *data, UInt32 size) PURE;
142 STDMETHOD(SetInitVector)(const Byte *data, UInt32 size) PURE;
146 CODER_INTERFACE(ICryptoResetSalt, 0x88)
148 STDMETHOD(ResetSalt)() PURE;
152 CODER_INTERFACE(ICryptoResetInitVector, 0x8C)
154 STDMETHOD(ResetInitVector)() PURE;
157 CODER_INTERFACE(ICryptoSetPassword, 0x90)
159 STDMETHOD(CryptoSetPassword)(const Byte *data, UInt32 size) PURE;
162 CODER_INTERFACE(ICryptoSetCRC, 0xA0)
164 STDMETHOD(CryptoSetCRC)(UInt32 crc) PURE;
167 //////////////////////
169 namespace NMethodPropID