ws2_32/tests: Wait for AFD_POLL_RESET in test_get_events_reset().
[wine.git] / include / mediaobj.idl
blob127b95e7fc3e8f722857a0b967d780f485a1779e
1 /*
2 * Copyright (C) 2002 Alexandre Julliard
3 * Copyright (C) 2004 Vincent BĂ©ron
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 import "unknwn.idl";
21 import "objidl.idl";
23 cpp_quote("#ifdef __strmif_h__")
24 cpp_quote("typedef AM_MEDIA_TYPE DMO_MEDIA_TYPE;")
25 cpp_quote("#else")
26 typedef struct _DMOMediaType
28 GUID majortype;
29 GUID subtype;
30 BOOL bFixedSizeSamples;
31 BOOL bTemporalCompression;
32 ULONG lSampleSize;
33 GUID formattype;
34 IUnknown *pUnk;
35 ULONG cbFormat;
36 BYTE *pbFormat;
37 } DMO_MEDIA_TYPE;
39 typedef LONGLONG REFERENCE_TIME;
40 cpp_quote("#endif")
42 /*****************************************************************************
43 * IEnumDMO interface
46 object,
47 uuid(2C3CD98A-2BFA-4A53-9C27-5249BA64BA0F),
48 pointer_default(unique)
50 interface IEnumDMO : IUnknown
52 [local]
53 HRESULT Next(
54 [in] DWORD cItemsToFetch,
55 [out] CLSID *pCLSID,
56 [out] WCHAR **Names,
57 [out] DWORD *pcItemsFetched
60 HRESULT Skip(
61 [in] DWORD cItemsToSkip
64 HRESULT Reset();
66 HRESULT Clone(
67 [out] IEnumDMO **ppEnum
71 /*****************************************************************************
72 * IMediaBuffer interface
75 object,
76 uuid(59eff8b9-938c-4a26-82f2-95cb84cdc837),
77 local
79 interface IMediaBuffer : IUnknown
81 HRESULT SetLength(
82 DWORD cbLength
85 HRESULT GetMaxLength(
86 [out] DWORD *pcbMaxLength
89 HRESULT GetBufferAndLength(
90 [out] BYTE **ppBuffer,
91 [out] DWORD *pcbLength
95 enum _DMO_INPUT_STATUS_FLAGS
97 DMO_INPUT_STATUSF_ACCEPT_DATA = 0x00000001,
100 enum _DMO_INPUT_DATA_BUFFER_FLAGS
102 DMO_INPUT_DATA_BUFFERF_SYNCPOINT = 0x00000001,
103 DMO_INPUT_DATA_BUFFERF_TIME = 0x00000002,
104 DMO_INPUT_DATA_BUFFERF_TIMELENGTH = 0x00000004,
107 enum _DMO_PROCESS_OUTPUT_FLAGS
109 DMO_PROCESS_OUTPUT_DISCARD_WHEN_NO_BUFFER = 0x00000001,
112 typedef struct _DMO_OUTPUT_DATA_BUFFER {
113 IMediaBuffer *pBuffer;
114 DWORD dwStatus;
115 REFERENCE_TIME rtTimestamp;
116 REFERENCE_TIME rtTimelength;
117 } DMO_OUTPUT_DATA_BUFFER, *PDMO_OUTPUT_DATA_BUFFER;
119 enum _DMO_INPLACE_PROCESS_FLAGS {
120 DMO_INPLACE_NORMAL = 0x00000000,
121 DMO_INPLACE_ZERO = 0x00000001
124 enum _DMO_SET_TYPE_FLAGS {
125 DMO_SET_TYPEF_TEST_ONLY = 0x00000001,
126 DMO_SET_TYPEF_CLEAR = 0x00000002,
129 enum _DMO_OUTPUT_DATA_BUFFERF_FLAGS {
130 DMO_OUTPUT_DATA_BUFFERF_SYNCPOINT = 0x00000001,
131 DMO_OUTPUT_DATA_BUFFERF_TIME = 0x00000002,
132 DMO_OUTPUT_DATA_BUFFERF_TIMELENGTH = 0x00000004,
133 DMO_OUTPUT_DATA_BUFFERF_INCOMPLETE = 0x01000000,
136 /*****************************************************************************
137 * IMediaObject interface
140 object,
141 uuid(d8ad0f58-5494-4102-97c5-ec798e59bcf4),
142 local
144 interface IMediaObject : IUnknown
146 HRESULT GetStreamCount(
147 [out] DWORD *pcInputStreams,
148 [out] DWORD *pcOutputStreams
151 HRESULT GetInputStreamInfo(
152 DWORD dwInputStreamIndex,
153 [out] DWORD *pdwFlags
156 HRESULT GetOutputStreamInfo(
157 DWORD dwOutputStreamIndex,
158 [out] DWORD *pdwFlags
161 HRESULT GetInputType(
162 DWORD dwInputStreamIndex,
163 DWORD dwTypeIndex,
164 [out] DMO_MEDIA_TYPE *pmt
167 HRESULT GetOutputType(
168 DWORD dwOutputStreamIndex,
169 DWORD dwTypeIndex,
170 [out] DMO_MEDIA_TYPE *pmt
173 HRESULT SetInputType(
174 DWORD dwInputStreamIndex,
175 [in] const DMO_MEDIA_TYPE *pmt,
176 DWORD dwFlags
179 HRESULT SetOutputType(
180 DWORD dwOutputStreamIndex,
181 [in] const DMO_MEDIA_TYPE *pmt,
182 DWORD dwFlags
185 HRESULT GetInputCurrentType(
186 DWORD dwInputStreamIndex,
187 [out] DMO_MEDIA_TYPE *pmt
190 HRESULT GetOutputCurrentType(
191 DWORD dwOutputStreamIndex,
192 [out] DMO_MEDIA_TYPE *pmt
195 HRESULT GetInputSizeInfo(
196 DWORD dwInputStreamIndex,
197 [out] DWORD *pcbSize,
198 [out] DWORD *pcbMaxLookahead,
199 [out] DWORD *pcbAlignment
202 HRESULT GetOutputSizeInfo(
203 DWORD dwOutputStreamIndex,
204 [out] DWORD *pcbSize,
205 [out] DWORD *pcbAlignment
208 HRESULT GetInputMaxLatency(
209 DWORD dwInputStreamIndex,
210 [out] REFERENCE_TIME *prtMaxLatency
213 HRESULT SetInputMaxLatency(
214 DWORD dwInputStreamIndex,
215 REFERENCE_TIME rtMaxLatency
218 HRESULT Flush();
220 HRESULT Discontinuity(DWORD dwInputStreamIndex);
222 HRESULT AllocateStreamingResources();
224 HRESULT FreeStreamingResources();
226 HRESULT GetInputStatus(
227 DWORD dwInputStreamIndex,
228 [out] DWORD *dwFlags
231 HRESULT ProcessInput(
232 DWORD dwInputStreamIndex,
233 IMediaBuffer *pBuffer,
234 DWORD dwFlags,
235 REFERENCE_TIME rtTimestamp,
236 REFERENCE_TIME rtTimelength
239 HRESULT ProcessOutput(
240 DWORD dwFlags,
241 DWORD cOutputBufferCount,
242 [in,out] DMO_OUTPUT_DATA_BUFFER *pOutputBuffers,
243 [out] DWORD *pdwStatus
246 HRESULT Lock(LONG bLock);
249 /*****************************************************************************
250 * IMediaObjectInPlace interface
254 object,
255 uuid(651b9ad0-0fc7-4aa9-9538-d89931010741),
256 local
258 interface IMediaObjectInPlace : IUnknown {
259 HRESULT Process(
260 [in] ULONG ulSize,
261 [in,out] BYTE* pData,
262 [in] REFERENCE_TIME refTimeStart,
263 [in] DWORD dwFlags
266 HRESULT Clone(
267 [out] IMediaObjectInPlace **ppMediaObject
270 HRESULT GetLatency(
271 [out] REFERENCE_TIME *pLatencyTime
275 enum _DMO_QUALITY_STATUS_FLAGS
277 DMO_QUALITY_STATUS_ENABLED = 0x00000001,
281 object,
282 uuid(65abea96-cf36-453f-af8a-705e98f16260),
283 local
285 interface IDMOQualityControl : IUnknown
287 HRESULT SetNow([in] REFERENCE_TIME now);
288 HRESULT SetStatus([in] DWORD flags);
289 HRESULT GetStatus([out] DWORD *flags);
292 enum _DMO_VIDEO_OUTPUT_STREAM_FLAGS
294 DMO_VOSF_NEEDS_PREVIOUS_SAMPLE = 0x00000001,
298 object,
299 uuid(be8f4f4e-5b16-4d29-b350-7f6b5d9298ac),
300 local
302 interface IDMOVideoOutputOptimizations : IUnknown
304 HRESULT QueryOperationModePreferences(ULONG index, DWORD *flags);
305 HRESULT SetOperationMode(ULONG index, DWORD flags);
306 HRESULT GetCurrentOperationMode(ULONG index, DWORD *flags);
307 HRESULT GetCurrentSampleRequirements(ULONG index, DWORD *flags);