2 * Copyright 2011 Vincent Povirk for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 import
"wincodec.idl";
22 typedef enum WICPersistOptions
{
23 WICPersistOptionsDefault
= 0x00000000,
24 WICPersistOptionsLittleEndian
= 0x00000001,
25 WICPersistOptionsBigEndian
= 0x00000002,
26 WICPersistOptionsStrictFormat
= 0x00000004,
27 WICPersistOptionsNoCacheStream
= 0x00000008,
28 WICPersistOptionsMask
= 0x0000FFFF
31 typedef enum WICMetadataCreationOptions
{
32 WICMetadataCreationDefault
= 0x00000000,
33 WICMetadataCreationAllowUnknown
= WICMetadataCreationDefault
,
34 WICMetadataCreationFailUnknown
= 0x00010000,
35 WICMetadataCreationMask
= 0xFFFF0000
36 } WICMetadataCreationOptions
;
38 cpp_quote
("DEFINE_GUID(GUID_MetadataFormatUnknown, 0xa45e592f,0x9078,0x4a7c,0xad,0xb5,0x4e,0xdc,0x4f,0xd6,0x1b,0x1f);")
39 cpp_quote
("DEFINE_GUID(GUID_MetadataFormatChunktEXt, 0x568d8936,0xc0a9,0x4923,0x90,0x5d,0xdf,0x2b,0x38,0x23,0x8f,0xbc);")
40 cpp_quote
("DEFINE_GUID(GUID_MetadataFormatIfd, 0x537396c6,0x2d8a,0x4bb6,0x9b,0xf8,0x2f,0x0a,0x8e,0x2a,0x3a,0xdf);")
41 cpp_quote
("DEFINE_GUID(GUID_MetadataFormatExif, 0x1c3c4f9d,0xb84a,0x467d,0x94,0x93,0x36,0xcf,0xbd,0x59,0xea,0x57);")
43 cpp_quote
("DEFINE_GUID(CLSID_WICUnknownMetadataReader, 0x699745c2,0x5066,0x4b82,0xa8,0xe3,0xd4,0x04,0x78,0xdb,0xec,0x8c);")
44 cpp_quote
("DEFINE_GUID(CLSID_WICUnknownMetadataWriter, 0xa09cca86,0x27ba,0x4f39,0x90,0x53,0x12,0x1f,0xa4,0xdc,0x08,0xfc);")
45 cpp_quote
("DEFINE_GUID(CLSID_WICPngTextMetadataReader, 0x4b59afcc,0xb8c3,0x408a,0xb6,0x70,0x89,0xe5,0xfa,0xb6,0xfd,0xa7);")
46 cpp_quote
("DEFINE_GUID(CLSID_WICPngTextMetadataWriter, 0xb5ebafb9,0x253e,0x4a72,0xa7,0x44,0x07,0x62,0xd2,0x68,0x56,0x83);")
47 cpp_quote
("DEFINE_GUID(CLSID_WICIfdMetadataReader, 0x8f914656,0x9d0a,0x4eb2,0x90,0x19,0x0b,0xf9,0x6d,0x8a,0x9e,0xe6);")
48 cpp_quote
("DEFINE_GUID(CLSID_WICExifMetadataReader, 0xd9403860,0x297f,0x4a49,0xbf,0x9b,0x77,0x89,0x81,0x50,0xa4,0x42);")
52 uuid(aba958bf
-c672
-44d1
-8d61
-ce6df2e682c2
)
54 interface IWICMetadataHandlerInfo
: IWICComponentInfo
56 HRESULT GetMetadataFormat
(
57 [out] GUID
*pguidMetadataFormat
);
59 HRESULT GetContainerFormats
(
60 [in] UINT cContainerFormats
,
61 [in, out, unique, size_is(cContainerFormats
)] GUID
*pguidContainerFormats
,
62 [out] UINT
*pcchActual
);
64 HRESULT GetDeviceManufacturer
(
65 [in] UINT cchDeviceManufacturer
,
66 [in, out, unique, size_is(cchDeviceManufacturer
)] WCHAR
*wzDeviceManufacturer
,
67 [out] UINT
*pcchActual
);
69 HRESULT GetDeviceModels
(
70 [in] UINT cchDeviceModels
,
71 [in, out, unique, size_is(cchDeviceModels
)] WCHAR
*wzDeviceModels
,
72 [out] UINT
*pcchActual
);
74 HRESULT DoesRequireFullStream
(
75 [out] BOOL
*pfRequiresFullStream
);
77 HRESULT DoesSupportPadding
(
78 [out] BOOL
*pfSupportsPadding
);
80 HRESULT DoesRequireFixedSize
(
81 [out] BOOL
*pfFixedSize
);
86 uuid(9204fe99
-d8fc
-4fd5
-a001
-9536b067a899
)
88 interface IWICMetadataReader
: IUnknown
90 HRESULT GetMetadataFormat
(
91 [out] GUID
*pguidMetadataFormat
);
93 HRESULT GetMetadataHandlerInfo
(
94 [out] IWICMetadataHandlerInfo
**ppIHandler
);
99 HRESULT GetValueByIndex
(
101 [in, out, unique] PROPVARIANT
*pvarSchema
,
102 [in, out, unique] PROPVARIANT
*pvarId
,
103 [in, out, unique] PROPVARIANT
*pvarValue
);
106 [in] const PROPVARIANT
*pvarSchema
,
107 [in] const PROPVARIANT
*pvarId
,
108 [in, out, unique] PROPVARIANT
*pvarValue
);
110 HRESULT GetEnumerator
(
111 [out] IWICEnumMetadataItem
**ppIEnumMetadata
);
116 uuid(f7836e16
-3be0
-470b
-86bb
-160d0aecd7de
)
118 interface IWICMetadataWriter
: IWICMetadataReader
121 [in, unique] const PROPVARIANT
*pvarSchema
,
122 [in] const PROPVARIANT
*pvarId
,
123 [in] const PROPVARIANT
*pvarValue
);
125 HRESULT SetValueByIndex
(
127 [in, unique] const PROPVARIANT
*pvarSchema
,
128 [in] const PROPVARIANT
*pvarId
,
129 [in] const PROPVARIANT
*pvarValue
);
132 [in, unique] const PROPVARIANT
*pvarSchema
,
133 [in] const PROPVARIANT
*pvarId
);
135 HRESULT RemoveValueByIndex
(
141 uuid(feaa2a8d
-b3f3
-43e4
-b25c
-d1de990a1ae1
)
143 interface IWICMetadataBlockReader
: IUnknown
145 HRESULT GetContainerFormat
(
146 [out] GUID
*pguidContainerFormat
);
149 [out] UINT
*pcCount
);
151 HRESULT GetReaderByIndex
(
153 [out] IWICMetadataReader
**ppIMetadataReader
);
155 HRESULT GetEnumerator
(
156 [out] IEnumUnknown
**ppIEnumMetadata
);
161 uuid(08fb9676
-b444
-41e8
-8dbe
-6a53a542bff1
)
163 interface IWICMetadataBlockWriter
: IWICMetadataBlockReader
165 HRESULT InitializeFromBlockReader
(
166 [in] IWICMetadataBlockReader
*pIMDBlockReader
);
168 HRESULT GetWriterByIndex
(
170 [out] IWICMetadataWriter
**ppIMetadataWriter
);
173 [in] IWICMetadataWriter
*pIMetadataWriter
);
175 HRESULT SetWriterByIndex
(
177 [in] IWICMetadataWriter
*pIMetadataWriter
);
179 HRESULT RemoveWriterByIndex
(
185 uuid(00675040-6908-45f8
-86a3
-49c7dfd6d9ad
)
187 interface IWICPersistStream
: IPersistStream
190 [in, unique] IStream
*pIStream
,
191 [in, unique] const GUID
*pguidPreferredVendor
,
192 [in] DWORD dwPersistOptions
);
195 [in] IStream
*pIStream
,
196 [in] DWORD dwPersistOptions
,
197 [in] BOOL fClearDirty
);
202 uuid(412d0c3a
-9650-44fa
-af5b
-dd2a06c8e8fb
)
204 interface IWICComponentFactory
: IWICImagingFactory
206 HRESULT CreateMetadataReader
(
207 [in] REFGUID guidMetadataFormat
,
208 [in, unique] const GUID
*pguidVendor
,
209 [in] DWORD dwOptions
,
210 [in] IStream
*pIStream
,
211 [out] IWICMetadataReader
**ppIReader
);
213 HRESULT CreateMetadataReaderFromContainer
(
214 [in] REFGUID guidMetadataFormat
,
215 [in, unique] const GUID
*pguidVendor
,
216 [in] DWORD dwOptions
,
217 [in] IStream
*pIStream
,
218 [out] IWICMetadataReader
**ppIReader
);
220 HRESULT CreateMetadataWriter
(
221 [in] REFGUID guidMetadataFormat
,
222 [in, unique] const GUID
*pguidVendor
,
223 [in] DWORD dwMetadataOptions
,
224 [out] IWICMetadataWriter
**ppIWriter
);
226 HRESULT CreateMetadataWriterFromReader
(
227 [in] IWICMetadataReader
*pIReader
,
228 [in, unique] const GUID
*pguidVendor
,
229 [out] IWICMetadataWriter
**ppIWriter
);
231 HRESULT CreateQueryReaderFromBlockReader
(
232 [in] IWICMetadataBlockReader
*pIBlockReader
,
233 [out] IWICMetadataQueryReader
**ppIQueryReader
);
235 HRESULT CreateQueryWriterFromBlockWriter
(
236 [in] IWICMetadataBlockWriter
*pIBlockWriter
,
237 [out] IWICMetadataQueryWriter
**ppIQueryWriter
);
239 HRESULT CreateEncoderPropertyBag
(
240 [in, unique, size_is(cCount
)] PROPBAG2
*ppropOptions
,
242 [out] IPropertyBag2
**ppIPropertyBag
);