rpcrt4: Added prepare_async_request helper.
[wine/multimedia.git] / include / wmsdkidl.idl
blob589d6ae3f2fcb20ce0bb3be9a07bd06be5aa9fe8
1 /*
2 * Copyright 2012 André Hentschel
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 "oaidl.idl";
20 import "wmsbuffer.idl";
21 /* import "drmexternals.idl"; */
23 typedef unsigned __int64 QWORD;
25 typedef struct _WMMediaType
27 GUID majortype;
28 GUID subtype;
29 BOOL bFixedSizeSamples;
30 BOOL bTemporalCompression;
31 ULONG lSampleSize;
32 GUID formattype;
33 IUnknown *pUnk;
34 ULONG cbFormat;
35 [size_is(cbFormat)] BYTE *pbFormat;
36 } WM_MEDIA_TYPE;
38 typedef enum WMT_ATTR_DATATYPE
40 WMT_TYPE_DWORD = 0,
41 WMT_TYPE_STRING = 1,
42 WMT_TYPE_BINARY = 2,
43 WMT_TYPE_BOOL = 3,
44 WMT_TYPE_QWORD = 4,
45 WMT_TYPE_WORD = 5,
46 WMT_TYPE_GUID = 6,
47 } WMT_ATTR_DATATYPE;
49 typedef enum WMT_STATUS
51 WMT_ERROR = 0,
52 WMT_OPENED = 1,
53 WMT_BUFFERING_START = 2,
54 WMT_BUFFERING_STOP = 3,
55 WMT_EOF = 4,
56 WMT_END_OF_FILE = 4,
57 WMT_END_OF_SEGMENT = 5,
58 WMT_END_OF_STREAMING = 6,
59 WMT_LOCATING = 7,
60 WMT_CONNECTING = 8,
61 WMT_NO_RIGHTS = 9,
62 WMT_MISSING_CODEC = 10,
63 WMT_STARTED = 11,
64 WMT_STOPPED = 12,
65 WMT_CLOSED = 13,
66 WMT_STRIDING = 14,
67 WMT_TIMER = 15,
68 WMT_INDEX_PROGRESS = 16,
69 WMT_SAVEAS_START = 17,
70 WMT_SAVEAS_STOP = 18,
71 WMT_NEW_SOURCEFLAGS = 19,
72 WMT_NEW_METADATA = 20,
73 WMT_BACKUPRESTORE_BEGIN = 21,
74 WMT_SOURCE_SWITCH = 22,
75 WMT_ACQUIRE_LICENSE = 23,
76 WMT_INDIVIDUALIZE = 24,
77 WMT_NEEDS_INDIVIDUALIZATION = 25,
78 WMT_NO_RIGHTS_EX = 26,
79 WMT_BACKUPRESTORE_END = 27,
80 WMT_BACKUPRESTORE_CONNECTING = 28,
81 WMT_BACKUPRESTORE_DISCONNECTING = 29,
82 WMT_ERROR_WITHURL = 30,
83 WMT_RESTRICTED_LICENSE = 31,
84 WMT_CLIENT_CONNECT = 32,
85 WMT_CLIENT_DISCONNECT = 33,
86 WMT_NATIVE_OUTPUT_PROPS_CHANGED = 34,
87 WMT_RECONNECT_START = 35,
88 WMT_RECONNECT_END = 36,
89 WMT_CLIENT_CONNECT_EX = 37,
90 WMT_CLIENT_DISCONNECT_EX = 38,
91 WMT_SET_FEC_SPAN = 39,
92 WMT_PREROLL_READY = 40,
93 WMT_PREROLL_COMPLETE = 41,
94 WMT_CLIENT_PROPERTIES = 42,
95 WMT_LICENSEURL_SIGNATURE_STATE = 43,
96 WMT_INIT_PLAYLIST_BURN = 44,
97 WMT_TRANSCRYPTOR_INIT = 45,
98 WMT_TRANSCRYPTOR_SEEKED = 46,
99 WMT_TRANSCRYPTOR_READ = 47,
100 WMT_TRANSCRYPTOR_CLOSED = 48,
101 WMT_PROXIMITY_RESULT = 49,
102 WMT_PROXIMITY_COMPLETED = 50,
103 WMT_CONTENT_ENABLER = 51
104 } WMT_STATUS;
106 typedef enum WMT_STREAM_SELECTION
108 WMT_OFF = 0,
109 WMT_CLEANPOINT_ONLY = 1,
110 WMT_ON = 2,
111 } WMT_STREAM_SELECTION;
115 object,
116 uuid(6d7cdc70-9888-11d3-8edc-00c04f6109cf),
117 pointer_default(unique),
118 local
120 interface IWMStatusCallback : IUnknown
122 HRESULT OnStatus(
123 [in] WMT_STATUS Status,
124 [in] HRESULT hr,
125 [in] WMT_ATTR_DATATYPE dwType,
126 [in] BYTE *pValue,
127 [in] void *pvContext);
131 object,
132 uuid(96406bd8-2b2b-11d3-b36b-00c04f6108ff),
133 pointer_default(unique),
134 local
136 interface IWMReaderCallback : IWMStatusCallback
138 HRESULT OnSample(
139 [in] DWORD dwOutputNum,
140 [in] QWORD cnsSampleTime,
141 [in] QWORD cnsSampleDuration,
142 [in] DWORD dwFlags,
143 [in] INSSBuffer *pSample,
144 [in] void *pvContext);
148 object,
149 uuid(96406bce-2b2b-11d3-b36b-00c04f6108ff),
150 pointer_default(unique),
151 local
153 interface IWMMediaProps : IUnknown
155 HRESULT GetType(
156 [out] GUID *pguidType);
158 HRESULT GetMediaType(
159 [out] WM_MEDIA_TYPE *pType,
160 [in, out] DWORD *pcbType);
162 HRESULT SetMediaType(
163 [in] WM_MEDIA_TYPE *pType);
167 object,
168 uuid(96406bd7-2b2b-11d3-b36b-00c04f6108ff),
169 pointer_default(unique),
170 local
172 interface IWMOutputMediaProps : IWMMediaProps
174 HRESULT GetStreamGroupName(
175 [out, size_is(*pcchName)] WCHAR *pwszName,
176 [in, out] WORD *pcchName);
178 HRESULT GetConnectionName(
179 [out, size_is(*pcchName)] WCHAR *pwszName,
180 [in, out] WORD *pcchName);
184 object,
185 uuid(96406bd6-2b2b-11d3-b36b-00c04f6108ff),
186 pointer_default(unique),
187 local
189 interface IWMReader : IUnknown
191 HRESULT Open(
192 [in] const WCHAR *pwszURL,
193 [in] IWMReaderCallback *pCallback,
194 [in] void *pvContext);
196 HRESULT Close();
198 HRESULT GetOutputCount(
199 [out] DWORD *pcOutputs);
201 HRESULT GetOutputProps(
202 [in] DWORD dwOutputNum,
203 [out] IWMOutputMediaProps **ppOutput);
205 HRESULT SetOutputProps(
206 [in] DWORD dwOutputNum,
207 [in] IWMOutputMediaProps *pOutput);
209 HRESULT GetOutputFormatCount(
210 [in] DWORD dwOutputNumber,
211 [out] DWORD *pcFormats);
213 HRESULT GetOutputFormat(
214 [in] DWORD dwOutputNumber,
215 [in] DWORD dwFormatNumber,
216 [out] IWMOutputMediaProps** ppProps);
218 HRESULT Start(
219 [in] QWORD cnsStart,
220 [in] QWORD cnsDuration,
221 [in] float fRate,
222 [in] void *pvContext);
224 HRESULT Stop();
226 HRESULT Pause();
228 HRESULT Resume();
232 object,
233 uuid(9397f121-7705-4dc9-b049-98b698188414),
234 pointer_default( unique ),
235 local
237 interface IWMSyncReader : IUnknown
239 HRESULT Open(
240 [in] const WCHAR *pwszFilename);
242 HRESULT Close();
244 HRESULT SetRange(
245 [in] QWORD cnsStartTime,
246 [in] LONGLONG cnsDuration);
248 HRESULT SetRangeByFrame(
249 [in] WORD wStreamNum,
250 [in] QWORD qwFrameNumber,
251 [in] LONGLONG cFramesToRead);
253 HRESULT GetNextSample(
254 [in] WORD wStreamNum,
255 [out] INSSBuffer **ppSample,
256 [out] QWORD *pcnsSampleTime,
257 [out] QWORD *pcnsDuration,
258 [out] DWORD *pdwFlags,
259 [out] DWORD *pdwOutputNum,
260 [out] WORD *pwStreamNum);
262 HRESULT SetStreamsSelected(
263 [in] WORD cStreamCount,
264 [in] WORD *pwStreamNumbers,
265 [in] WMT_STREAM_SELECTION *pSelections);
267 HRESULT GetStreamSelected(
268 [in] WORD wStreamNum,
269 [out] WMT_STREAM_SELECTION *pSelection);
271 HRESULT SetReadStreamSamples(
272 [in] WORD wStreamNum,
273 [in] BOOL fCompressed);
275 HRESULT GetReadStreamSamples(
276 [in] WORD wStreamNum,
277 [out] BOOL *pfCompressed);
279 HRESULT GetOutputSetting(
280 [in] DWORD dwOutputNum,
281 [in] LPCWSTR pszName,
282 [out] WMT_ATTR_DATATYPE *pType,
283 [out, size_is(*pcbLength)] BYTE *pValue,
284 [in, out] WORD *pcbLength);
286 HRESULT SetOutputSetting(
287 [in] DWORD dwOutputNum,
288 [in] LPCWSTR pszName,
289 [in] WMT_ATTR_DATATYPE Type,
290 [in, size_is(cbLength)] const BYTE *pValue,
291 [in] WORD cbLength);
293 HRESULT GetOutputCount(
294 [out] DWORD *pcOutputs);
296 HRESULT GetOutputProps(
297 [in] DWORD dwOutputNum,
298 [out] IWMOutputMediaProps **ppOutput);
300 HRESULT SetOutputProps(
301 [in] DWORD dwOutputNum,
302 [in] IWMOutputMediaProps *pOutput);
304 HRESULT GetOutputFormatCount(
305 [in] DWORD dwOutputNum,
306 [out] DWORD *pcFormats);
308 HRESULT GetOutputFormat(
309 [in] DWORD dwOutputNum,
310 [in] DWORD dwFormatNum,
311 [out] IWMOutputMediaProps **ppProps);
313 HRESULT GetOutputNumberForStream(
314 [in] WORD wStreamNum,
315 [out] DWORD *pdwOutputNum);
317 HRESULT GetStreamNumberForOutput(
318 [in] DWORD dwOutputNum,
319 [out] WORD *pwStreamNum);
321 HRESULT GetMaxOutputSampleSize(
322 [in] DWORD dwOutput,
323 [out] DWORD *pcbMax);
325 HRESULT GetMaxStreamSampleSize(
326 [in] WORD wStream,
327 [out] DWORD *pcbMax);
329 HRESULT OpenStream(
330 [in] IStream *pStream);