mfplay: Forward playback control methods to the session.
[wine/zf.git] / include / devicetopology.idl
blob7e89d541ad6667f7ffbb2d7a43b7b3e9a9b5d0d5
1 /*
2 * Core Audio device topology definitions
4 * Copyright 2009 Maarten Lankhorst
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
22 interface IPart;
23 interface IControlInterface;
24 interface IDeviceTopology;
25 interface IControlChangeNotify;
27 import "oaidl.idl";
28 import "ocidl.idl";
29 import "propidl.idl";
31 cpp_quote("#ifndef E_NOTFOUND")
32 cpp_quote("#define E_NOTFOUND HRESULT_FROM_WIN32(ERROR_NOT_FOUND)")
33 cpp_quote("#endif")
35 cpp_quote("#define DEVTOPO_HARDWARE_INITIATED_EVENTCONTEXT 0x64726148 /* 'draH' */")
36 cpp_quote("DEFINE_GUID(EVENTCONTEXT_VOLUMESLIDER, 0xe2c2e9de, 0x09b1, 0x4b04,0x84,0xe5, 0x07, 0x93, 0x12, 0x25, 0xee, 0x04);")
38 cpp_quote("#define _IKsControl_")
39 cpp_quote("#include <ks.h>")
40 cpp_quote("#include <ksmedia.h>")
41 cpp_quote("#ifndef _KS_")
43 typedef struct {
44 ULONG FormatSize;
45 ULONG Flags;
46 ULONG SampleSize;
47 ULONG Reserved;
48 GUID MajorFormat;
49 GUID SubFormat;
50 GUID Specifier;
51 } KSDATAFORMAT;
53 typedef KSDATAFORMAT *PKSDATAFORMAT;
55 typedef struct
57 union
59 struct {
60 GUID Set;
61 ULONG Id;
62 ULONG Flags;
64 LONGLONG Alignment;
66 } KSIDENTIFIER;
68 typedef KSIDENTIFIER KSPROPERTY, *PKSPROPERTY;
69 typedef KSIDENTIFIER KSMETHOD, *PKSMETHOD;
70 typedef KSIDENTIFIER KSEVENT, *PKSEVENT;
72 typedef enum
74 eConnTypeUnknown = 0,
75 eConnType3Point5mm,
76 eConnTypeQuarter,
77 eConnTypeAtapiInternal,
78 eConnTypeRCA,
79 eConnTypeOptical,
80 eConnTypeOtherDigital,
81 eConnTypeOtherAnalog,
82 eConnTypeMultichannelAnalogDIN,
83 eConnTypeXlrProfessional,
84 eConnTypeRJ11Modem,
85 eConnTypeCombination
86 } EPcxConnectionType;
88 typedef enum
90 eGeoLocRear = 1,
91 eGeoLocFront,
92 eGeoLocLeft,
93 eGeoLocRight,
94 eGeoLocTop,
95 eGeoLocBottom,
96 eGeoLocRearPanel,
97 eGeoLocRiser,
98 eGeoLocInsideMobileLid,
99 eGeoLocDrivebay,
100 eGeoLocHDMI,
101 eGeoLocOutsideMobileLid,
102 eGeoLocATAPI,
103 eGeoLocReserved5,
104 eGeoLocReserved6
105 } EPcxGeoLocation;
107 typedef enum
109 eGenLocPrimaryBox = 0,
110 eGenLocInternal,
111 eGenLocSeparate,
112 eGenLocOther
113 } EPcxGenLocation;
115 typedef enum
117 ePortConnJack = 0,
118 ePortConnIntegratedDevice,
119 ePortConnBothIntegratedAndJack,
120 ePortConnUnknown
121 } EPxcPortConnection;
123 typedef struct
125 DWORD ChannelMapping;
126 COLORREF Color;
127 EPcxConnectionType ConnectionType;
128 EPcxGeoLocation GeoLocation;
129 EPcxGenLocation GenLocation;
130 EPxcPortConnection PortConnection;
131 BOOL IsConnected;
132 } KSJACK_DESCRIPTION;
134 typedef KSJACK_DESCRIPTION *PKSJACK_DESCRIPTION;
136 typedef struct _LUID
138 DWORD LowPart;
139 LONG HighPart;
140 } LUID;
142 typedef struct _LUID *PLUID;
144 typedef enum
146 KSJACK_SINK_CONNECTIONTYPE_HDMI = 0,
147 KSJACK_SINK_CONNECTIONTYPE_DISPLAYPORT
148 } KSJACK_SINK_CONNECTIONTYPE;
150 typedef struct _tagKSJACK_SINK_INFORMATION
152 KSJACK_SINK_CONNECTIONTYPE ConnType;
153 WORD ManufacturerId;
154 WORD ProductId;
155 WORD AudioLatency;
156 BOOL HDCPCapable;
157 BOOL AICapable;
158 UCHAR SinkDescriptionLength;
159 WCHAR SinkDescription[32];
160 LUID PortId;
161 } KSJACK_SINK_INFORMATION;
163 typedef struct _tagKSJACK_DESCRIPTION2
165 DWORD DeviceStateInfo;
166 DWORD JackCapabilities;
167 } KSJACK_DESCRIPTION2;
169 typedef struct _tagKSJACK_DESCRIPTION2 *PKSJACK_DESCRIPTION2;
171 cpp_quote("#endif")
173 typedef enum
175 In = 0,
177 } DataFlow;
179 typedef enum
181 Connector = 0,
182 Subunit
183 } PartType;
185 typedef enum
187 Unknown_Connector = 0,
188 Physical_Internal,
189 Physical_External,
190 Software_IO,
191 Software_Fixed,
192 Network
193 } ConnectorType;
196 pointer_default(unique),
197 nonextensible,
198 uuid(28f54685-06fd-11d2-b27a-00a0c9223196),
199 local,
200 object
202 interface IKsControl : IUnknown
204 HRESULT KsProperty(
205 [in] PKSPROPERTY Property,
206 [in] ULONG PropertyLength,
207 [in,out] void *PropertyData,
208 [in] ULONG DataLength,
209 [out] ULONG *BytesReturned
211 HRESULT KsMethod(
212 [in] PKSMETHOD Method,
213 [in] ULONG MethodLength,
214 [in,out] void *MethodData,
215 [in] ULONG DataLength,
216 [out] ULONG *BytesReturned
218 HRESULT KsEvent(
219 [in] PKSEVENT Event,
220 [in] ULONG EventLength,
221 [in,out] void *EventData,
222 [in] ULONG DataLength,
223 [out] ULONG *BytesReturned
228 pointer_default(unique),
229 nonextensible,
230 uuid(c2f8e001-f205-4bc9-99bc-c13b1e048ccb),
231 local,
232 object
234 interface IPerChannelDbLevel : IUnknown
236 HRESULT GetChannelCount(
237 [out] UINT *pcChannels
239 HRESULT GetLevelRange(
240 [in] UINT nChannel,
241 [out] float *pfMinLevelDB,
242 [out] float *pfMaxLevelDB,
243 [out] float *pfStepping
245 HRESULT GetLevel(
246 [in] UINT nChannel,
247 [out] float *pfLevelDB
249 HRESULT SetLevel(
250 [in] UINT nChannel,
251 [in] float fLevelDB,
252 [in,unique] LPCGUID pguidEventContext
254 HRESULT SetLevelUniform(
255 [in] float fLevelDB,
256 [in,unique] LPCGUID pguidEventContext
258 HRESULT SetLevelAllChannels(
259 [size_is(cChannels),in] float *aLevelsDB,
260 [in] ULONG cChannels,
261 [in] LPCGUID pguidEventContext
266 pointer_default(unique),
267 nonextensible,
268 uuid(7fb7b48f-531d-44a2-bcb3-5ad5a134b3dc),
269 local,
270 object
272 interface IAudioVolumeLevel : IPerChannelDbLevel
274 /* Empty */
278 pointer_default(unique),
279 nonextensible,
280 uuid(bb11c46f-ec28-493c-b88a-5db88062ce98),
281 local,
282 object
284 interface IAudioChannelConfig : IUnknown
286 HRESULT SetChannelConfig(
287 [in] DWORD dwConfig,
288 [in] LPCGUID pguidEventContext
290 HRESULT GetChannelConfig(
291 [in] DWORD dwConfig,
292 [retval,out] DWORD *pdwConfig
297 pointer_default(unique),
298 nonextensible,
299 uuid(7d8b1437-dd53-4350-9c1b-1ee2890bf938),
300 local,
301 object
303 interface IAudioLoudness : IUnknown
305 HRESULT GetEnabled(
306 [out] BOOL *pbEnabled
308 HRESULT SetEnabled(
309 [in] BOOL bEnabled,
310 [in] LPCGUID pguidEventContext
315 pointer_default(unique),
316 nonextensible,
317 uuid(4f03dc02-5e6e-4653-8f72-a030c123d598),
318 local,
319 object
321 interface IAudioInputSelector : IUnknown
323 HRESULT GetSelection(
324 [out] UINT *pnIdSelected
326 HRESULT SetSelection(
327 [in] UINT nIdSelect,
328 [unique,in] LPCGUID pguidEventContext
333 pointer_default(unique),
334 nonextensible,
335 uuid(bb515f69-94a7-429e-8b9c-271b3f11a3ab),
336 local,
337 object
339 interface IAudioOutputSelector : IUnknown
341 HRESULT GetSelection(
342 [out] UINT *pnIdSelected
344 HRESULT SetSelection(
345 [in] UINT nIdSelect,
346 [unique,in] LPCGUID pguidEventContext
351 pointer_default(unique),
352 nonextensible,
353 uuid(df45aeea-b74a-4b6b-afad-2366b6aa012e),
354 local,
355 object
357 interface IAudioMute : IUnknown
359 HRESULT SetMute(
360 [in] BOOL bMute,
361 [unique,in] LPCGUID pguidEventContext
363 HRESULT GetMute(
364 [out] BOOL *pbMute
369 pointer_default(unique),
370 nonextensible,
371 uuid(a2b1a1d9-4db3-425d-a2b2-bd335cb3e2e5),
372 local,
373 object
375 interface IAudioBass : IPerChannelDbLevel
377 /* Empty */
381 pointer_default(unique),
382 nonextensible,
383 uuid(5e54b6d7-b44b-40d9-9a9e-e691d9ce6edf),
384 local,
385 object
387 interface IAudioMidRange : IPerChannelDbLevel
389 /* Empty */
393 pointer_default(unique),
394 nonextensible,
395 uuid(0a717812-694e-4907-b74b-bafa5cfdca7b),
396 local,
397 object
399 interface IAudioTreble : IPerChannelDbLevel
401 /* Empty */
405 pointer_default(unique),
406 nonextensible,
407 uuid(85401fd4-6de4-4b9d-9869-2d6753a82f3c),
408 local,
409 object
411 interface IAudioAutoGainControl : IUnknown
413 HRESULT GetEnabled(
414 [in] BOOL bEnabled,
415 [unique,in] LPCGUID pguidEventContext
417 HRESULT GetMute(
418 [out] BOOL *pbEnabled
423 pointer_default(unique),
424 nonextensible,
425 uuid(dd79923c-0599-45e0-b8b6-c8df7db6e796),
426 local,
427 object
429 interface IAudioPeakMeter : IUnknown
431 HRESULT GetChannelCount(
432 [out] UINT *pcChannels
434 HRESULT GetLevel(
435 [in] UINT nChannel,
436 [out] float *pfLevel
441 pointer_default(unique),
442 nonextensible,
443 uuid(3b22bcbf-2586-4af0-8583-205d391b807c),
444 local,
445 object
447 interface IDeviceSpecificProperty : IUnknown
449 HRESULT GetType(
450 [out] VARTYPE *pVType
452 HRESULT GetValue(
453 [out] VARTYPE *pvType,
454 [out,in] DWORD *pcbValue
456 HRESULT SetValue(
457 [in] void *pvValue,
458 [in] DWORD cbValue,
459 [in] LPCGUID pguidEventContext
461 HRESULT Get4BRange(
462 [out] LONG *plMin,
463 [out] LONG *plMax,
464 [out] LONG *plStepping
469 pointer_default(unique),
470 nonextensible,
471 uuid(3cb4a69d-bb6f-4d2b-95b7-452d2c155db5),
472 local,
473 object
475 interface IKsFormatSupport : IUnknown
477 HRESULT IsFormatSupported(
478 [size_is(cbFormat),in] PKSDATAFORMAT pKsFormat,
479 [in] DWORD cbFormat,
480 [out] BOOL *pbSupported
482 HRESULT GetDevicePreferredFormat(
483 [out] PKSDATAFORMAT *ppKsFormat
488 pointer_default(unique),
489 nonextensible,
490 uuid(4509f757-2d46-4637-8e62-ce7db944f57b),
491 local,
492 object
494 interface IKsJackDescription : IUnknown
496 HRESULT GetJackCount(
497 [out] UINT *pcJacks
499 HRESULT GetJackDescription(
500 [in] UINT nJack,
501 [out] KSJACK_DESCRIPTION *pDescription
506 pointer_default(unique),
507 nonextensible,
508 uuid(478f3a9b-e0c9-4827-9228-6f5505ffe76a),
509 local,
510 object
512 interface IKsJackDescription2 : IUnknown
514 HRESULT GetJackCount(
515 [out] UINT *pcJacks
517 HRESULT GetJackDescription2(
518 [in] UINT nJack,
519 [out] KSJACK_DESCRIPTION2 *pDescription2
524 pointer_default(unique),
525 nonextensible,
526 uuid(d9bd72ed-290f-4581-9ff3-61027a8fe532),
527 local,
528 object
530 interface IKsJackSinkInformation : IUnknown
532 HRESULT GetJackSinkInformation(
533 [out] KSJACK_SINK_INFORMATION *pJackSinkInformation
538 pointer_default(unique),
539 nonextensible,
540 uuid(6daa848c-5eb0-45cc-aea5-998a2cda1ffb),
541 local,
542 object
544 interface IPartsList : IUnknown
546 HRESULT GetCount(
547 [out] UINT *pCount
549 HRESULT GetPart(
550 [in] UINT nIndex,
551 [out] IPart **ppPart
556 pointer_default(unique),
557 nonextensible,
558 uuid(ae2de0e4-5bca-4f2d-aa46-5d13f8fdb3a9),
559 local,
560 object
562 interface IPart : IUnknown
564 HRESULT GetName(
565 [out] LPWSTR *ppwstrName
567 HRESULT GetLocalId(
568 [out] UINT *pnId
570 HRESULT GetGlobalId(
571 [out] LPWSTR *ppwstrGlobalId
573 HRESULT GetPartType(
574 [out] PartType *pPartType
576 HRESULT GetSubType(
577 [out] GUID *pSubType
579 HRESULT GetControlInterfaceCount(
580 [out] UINT *pCount
582 HRESULT GetControlInterface(
583 [in] UINT nIndex,
584 [out] IControlInterface **ppInterfaceDesc
586 HRESULT EnumPartsIncoming(
587 [out] IPartsList **ppParts
589 HRESULT EnumPartsOutgoing(
590 [out] IPartsList **ppParts
592 HRESULT GetTopologyObjects(
593 [out] IDeviceTopology **ppTopology
595 HRESULT Activate(
596 [in] DWORD dwClsContext,
597 [in] REFIID refiid,
598 [iid_is(refiid),out] void **ppvObject
600 HRESULT RegisterControlChangeCallback(
601 [in] REFGUID riid,
602 [in] IControlChangeNotify *pNotify
604 HRESULT UnregisterControlChangeCallback(
605 [in] IControlChangeNotify *pNotify
610 pointer_default(unique),
611 nonextensible,
612 uuid(9c2c4058-23f5-41de-877a-df3af236a09e),
613 local,
614 object
616 interface IConnector : IUnknown
618 HRESULT GetType(
619 [out] ConnectorType *pType
621 HRESULT GetDataFlow(
622 [out] DataFlow *pFlow
624 HRESULT ConnectTo(
625 [in] IConnector *pConnectTo
627 HRESULT Disconnect(void);
628 HRESULT IsConnected(
629 [out] BOOL *pbConnected
631 HRESULT GetConnectedTo(
632 [out] IConnector **ppConTo
634 HRESULT GetConnectorIdConnectedTo(
635 [out] LPWSTR *ppwstrConnectorId
637 HRESULT GetDeviceIdConnectedTo(
638 [out] LPWSTR *ppwstrDeviceId
643 pointer_default(unique),
644 nonextensible,
645 uuid(82149a85-dba6-4487-86bb-ea8f7fefcc71),
646 local,
647 object
649 interface ISubUnit: IUnknown
651 /* Empty IUnknown interface.. */
655 pointer_default(unique),
656 nonextensible,
657 uuid(45d37c3f-5140-444a-ae24-400789f3cbf3),
658 local,
659 object
661 interface IControlInterface : IUnknown
663 HRESULT GetName(
664 [out] LPWSTR *ppwstrName
666 HRESULT GetIID(
667 [out] GUID *pIID
672 pointer_default(unique),
673 nonextensible,
674 uuid(a09513ed-c709-4d21-bd7b-5f34c47f3947),
675 local,
676 object
678 interface IControlChangeNotify : IUnknown
680 HRESULT OnNotify(
681 [in] DWORD dwSenderProcessId,
682 [in] LPCGUID ppguidEventContext
687 pointer_default(unique),
688 nonextensible,
689 uuid(2a07407e-6497-4a18-9787-32f79bd0d98f),
690 local,
691 object
693 interface IDeviceTopology : IUnknown
695 HRESULT GetConnectorCount(
696 [out] UINT *pCount
698 HRESULT GetConnector(
699 [in] UINT nIndex,
700 [out] IConnector **ppConnector
702 HRESULT GetSubunitCount(
703 [out] UINT *pCount
705 HRESULT GetSubunit(
706 [in] UINT nIndex,
707 [out] ISubUnit **ppConnector
709 HRESULT GetPartById(
710 [in] UINT nId,
711 [out] IPart **ppPart
713 HRESULT GetDeviceId(
714 [out] LPWSTR *ppwstrDeviceId
716 HRESULT GetSignalPath(
717 [in] IPart *pIPartFrom,
718 [in] IPart *pIPartTo,
719 [in] BOOL bRejectMixedPaths,
720 [out] IPartsList **ppParts
725 uuid(51b9a01d-8181-4363-b59c-e678f476dd0e),
726 version(1.0)
728 library DevTopologyLib
731 uuid(1df639d0-5ec1-47aa-9379-828dc1aa8c59),
733 coclass DeviceTopology
735 interface IDeviceTopology;