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
19 import "wincodec.idl";
21 typedef enum WICPersistOptions {
22 WICPersistOptionsDefault = 0x00000000,
23 WICPersistOptionsLittleEndian = 0x00000001,
24 WICPersistOptionsBigEndian = 0x00000002,
25 WICPersistOptionsStrictFormat = 0x00000004,
26 WICPersistOptionsNoCacheStream = 0x00000008,
27 WICPersistOptionsMask = 0x0000FFFF
30 typedef enum WICMetadataCreationOptions {
31 WICMetadataCreationDefault = 0x00000000,
32 WICMetadataCreationAllowUnknown = WICMetadataCreationDefault,
33 WICMetadataCreationFailUnknown = 0x00010000,
34 WICMetadataCreationMask = 0xFFFF0000
35 } WICMetadataCreationOptions;
39 uuid(aba958bf-c672-44d1-8d61-ce6df2e682c2)
41 interface IWICMetadataHandlerInfo : IWICComponentInfo
43 HRESULT GetMetadataFormat(
44 [out] GUID *pguidMetadataFormat);
46 HRESULT GetContainerFormats(
47 [in] UINT cContainerFormats,
48 [in, out, unique, size_is(cContainerFormats)] GUID *pguidContainerFormats,
49 [out] UINT *pcchActual);
51 HRESULT GetDeviceManufacturer(
52 [in] UINT cchDeviceManufacturer,
53 [in, out, unique, size_is(cchDeviceManufacturer)] WCHAR *wzDeviceManufacturer,
54 [out] UINT *pcchActual);
56 HRESULT GetDeviceModels(
57 [in] UINT cchDeviceModels,
58 [in, out, unique, size_is(cchDeviceModels)] WCHAR *wzDeviceModels,
59 [out] UINT *pcchActual);
61 HRESULT DoesRequireFullStream(
62 [out] BOOL *pfRequiresFullStream);
64 HRESULT DoesSupportPadding(
65 [out] BOOL *pfSupportsPadding);
67 HRESULT DoesRequireFixedSize(
68 [out] BOOL *pfFixedSize);
73 uuid(9204fe99-d8fc-4fd5-a001-9536b067a899)
75 interface IWICMetadataReader : IUnknown
77 HRESULT GetMetadataFormat(
78 [out] GUID *pguidMetadataFormat);
80 HRESULT GetMetadataHandlerInfo(
81 [out] IWICMetadataHandlerInfo **ppIHandler);
86 HRESULT GetValueByIndex(
88 [in, out, unique] PROPVARIANT *pvarSchema,
89 [in, out, unique] PROPVARIANT *pvarId,
90 [in, out, unique] PROPVARIANT *pvarValue);
93 [in] const PROPVARIANT *pvarSchema,
94 [in] const PROPVARIANT *pvarId,
95 [in, out, unique] const PROPVARIANT *pvarValue);
97 HRESULT GetEnumerator(
98 [out] IWICEnumMetadataItem **ppIEnumMetadata);
103 uuid(f7836e16-3be0-470b-86bb-160d0aecd7de)
105 interface IWICMetadataWriter : IWICMetadataReader
108 [in, unique] const PROPVARIANT *pvarSchema,
109 [in] const PROPVARIANT *pvarId,
110 [in] const PROPVARIANT *pvarValue);
112 HRESULT SetValueByIndex(
114 [in, unique] const PROPVARIANT *pvarSchema,
115 [in] const PROPVARIANT *pvarId,
116 [in] const PROPVARIANT *pvarValue);
119 [in, unique] const PROPVARIANT *pvarSchema,
120 [in] const PROPVARIANT *pvarId);
122 HRESULT RemoveValueByIndex(
128 uuid(feaa2a8d-b3f3-43e4-b25c-d1de990a1ae1)
130 interface IWICMetadataBlockReader : IUnknown
132 HRESULT GetContainerFormat(
133 [out] GUID *pguidContainerFormat);
136 [out] UINT *pcCount);
138 HRESULT GetReaderByIndex(
140 [out] IWICMetadataReader **ppIMetadataReader);
142 HRESULT GetEnumerator(
143 [out] IEnumUnknown **ppIEnumMetadata);
148 uuid(08fb9676-b444-41e8-8dbe-6a53a542bff1)
150 interface IWICMetadataBlockWriter : IWICMetadataBlockReader
152 HRESULT InitializeFromBlockReader(
153 [in] IWICMetadataBlockReader *pIMDBlockReader);
155 HRESULT GetWriterByIndex(
157 [out] IWICMetadataWriter **ppIMetadataWriter);
160 [in] IWICMetadataWriter *pIMetadataWriter);
162 HRESULT SetWriterByIndex(
164 [in] IWICMetadataWriter *pIMetadataWriter);
166 HRESULT RemoveWriterByIndex(
172 uuid(412d0c3a-9650-44fa-af5b-dd2a06c8e8fb)
174 interface IWICComponentFactory : IWICImagingFactory
176 HRESULT CreateMetadataReader(
177 [in] REFGUID guidMetadataFormat,
178 [in, unique] const GUID *pguidVendor,
179 [in] DWORD dwOptions,
180 [in] IStream *pIStream,
181 [out] IWICMetadataReader **ppIReader);
183 HRESULT CreateMetadataReaderFromContainer(
184 [in] REFGUID guidMetadataFormat,
185 [in, unique] const GUID *pguidVendor,
186 [in] DWORD dwOptions,
187 [in] IStream *pIStream,
188 [out] IWICMetadataReader **ppIReader);
190 HRESULT CreateMetadataWriter(
191 [in] REFGUID guidMetadataFormat,
192 [in, unique] const GUID *pguidVendor,
193 [in] DWORD dwMetadataOptions,
194 [out] IWICMetadataWriter **ppIWriter);
196 HRESULT CreateMetadataWriterFromReader(
197 [in] IWICMetadataReader *pIReader,
198 [in, unique] const GUID *pguidVendor,
199 [out] IWICMetadataWriter **ppIWriter);
201 HRESULT CreateQueryReaderFromBlockReader(
202 [in] IWICMetadataBlockReader *pIBlockReader,
203 [out] IWICMetadataQueryReader **ppIQueryReader);
205 HRESULT CreateQueryWriterFromBlockWriter(
206 [in] IWICMetadataBlockWriter *pIBlockWriter,
207 [out] IWICMetadataQueryWriter **ppIQueryWriter);
209 HRESULT CreateEncoderPropertyBag(
210 [in, unique, size_is(cCount)] PROPBAG2 *ppropOptions,
212 [out] IPropertyBag2 **ppIPropertyBag);