user32/tests: Account for some messages from dual-monitor setups.
[wine.git] / include / xapo.idl
blob841793d4fa5ccd9179c43d8aee97d3fa4f4c1464
1 /*
2 * Copyright (c) 2015 Andrew Eikum 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 "unknwn.idl";
21 #define XAPO_REGISTRATION_STRING_LENGTH 256
23 cpp_quote("#define XAPO_FLAG_CHANNELS_MUST_MATCH 0x1")
24 cpp_quote("#define XAPO_FLAG_FRAMERATE_MUST_MATCH 0x2")
25 cpp_quote("#define XAPO_FLAG_BITSPERSAMPLE_MUST_MATCH 0x4")
26 cpp_quote("#define XAPO_FLAG_BUFFERCOUNT_MUST_MATCH 0x8")
27 cpp_quote("#define XAPO_FLAG_INPLACE_SUPPORTED 0x10")
28 cpp_quote("#define XAPO_FLAG_INPLACE_REQUIRED 0x20")
30 cpp_quote("#if 0")
31 typedef struct WAVEFORMATEX
33 WORD wFormatTag;
34 WORD nChannels;
35 DWORD nSamplesPerSec;
36 DWORD nAvgBytesPerSec;
37 WORD nBlockAlign;
38 WORD wBitsPerSample;
39 WORD cbSize;
40 } WAVEFORMATEX;
42 typedef struct {
43 WAVEFORMATEX Format;
44 union {
45 WORD wValidBitsPerSample;
46 WORD wSamplesPerBlock;
47 WORD wReserved;
48 } Samples;
49 DWORD dwChannelMask;
50 GUID SubFormat;
51 } WAVEFORMATEXTENSIBLE, *PWAVEFORMATEXTENSIBLE;
52 cpp_quote("#else")
53 cpp_quote("#include <mmreg.h>")
54 cpp_quote("#endif")
56 typedef struct XAPO_REGISTRATION_PROPERTIES
58 CLSID clsid;
59 WCHAR FriendlyName[XAPO_REGISTRATION_STRING_LENGTH];
60 WCHAR CopyrightInfo[XAPO_REGISTRATION_STRING_LENGTH];
61 UINT32 MajorVersion;
62 UINT32 MinorVersion;
63 UINT32 Flags;
64 UINT32 MinInputBufferCount;
65 UINT32 MaxInputBufferCount;
66 UINT32 MinOutputBufferCount;
67 UINT32 MaxOutputBufferCount;
68 } XAPO_REGISTRATION_PROPERTIES;
70 typedef struct XAPO20_REGISTRATION_PROPERTIES
72 CLSID clsid;
73 WCHAR FriendlyName[XAPO_REGISTRATION_STRING_LENGTH];
74 WCHAR CopyrightInfo[XAPO_REGISTRATION_STRING_LENGTH];
75 UINT32 MajorVersion;
76 UINT32 MinorVersion;
77 UINT32 Flags;
78 UINT32 MinInputBufferCount;
79 UINT32 MaxInputBufferCount;
80 UINT32 MinOutputBufferCount;
81 UINT32 MaxOutputBufferCount;
82 UINT32 InterfaceCount;
83 IID InterfaceArray[1];
84 } XAPO20_REGISTRATION_PROPERTIES;
86 typedef struct XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS {
87 const WAVEFORMATEX *pFormat;
88 UINT32 MaxFrameCount;
89 } XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS;
91 typedef enum XAPO_BUFFER_FLAGS {
92 XAPO_BUFFER_SILENT,
93 XAPO_BUFFER_VALID
94 } XAPO_BUFFER_FLAGS;
96 typedef struct XAPO_PROCESS_BUFFER_PARAMETERS {
97 void *pBuffer;
98 XAPO_BUFFER_FLAGS BufferFlags;
99 UINT32 ValidFrameCount;
100 } XAPO_PROCESS_BUFFER_PARAMETERS;
102 /* XAudio2 2.8 version of IXAPO */
104 object,
105 local,
106 uuid(a410b984-9839-4819-a0be-2856ae6b3adb)
108 interface IXAPO : IUnknown
110 HRESULT GetRegistrationProperties([out] XAPO_REGISTRATION_PROPERTIES **props);
112 HRESULT IsInputFormatSupported(const WAVEFORMATEX *output_fmt,
113 const WAVEFORMATEX *input_fmt, WAVEFORMATEX **supported_fmt);
115 HRESULT IsOutputFormatSupported(const WAVEFORMATEX *input_fmt,
116 const WAVEFORMATEX *output_fmt, WAVEFORMATEX **supported_fmt);
118 HRESULT Initialize(const void *data, UINT32 data_len);
120 void Reset(void);
122 HRESULT LockForProcess(UINT32 in_params_count, const XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS *in_params,
123 UINT32 out_params_count, const XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS *out_params);
125 void UnlockForProcess(void);
127 void Process(UINT32 in_params_count, const XAPO_PROCESS_BUFFER_PARAMETERS *in_params,
128 UINT32 out_params_count, XAPO_PROCESS_BUFFER_PARAMETERS *out_params,
129 BOOL enabled);
131 UINT32 CalcInputFrames(UINT32 output_frames);
133 UINT32 CalcOutputFrames(UINT32 input_frames);
136 /* XAudio2 2.7 version of IXAPO is identical to 2.8 */
137 cpp_quote("DEFINE_GUID(IID_IXAPO27, 0xa90bc001, 0xe897, 0xe897, 0x55, 0xe4, 0x9e, 0x47, 0x00, 0x00, 0x00, 0x00);")
140 /* XAudio2 2.8 version of IXAPOParameters */
142 object,
143 local,
144 uuid(26d95c66-80f2-499a-ad54-5ae7f01c6d98)
146 interface IXAPOParameters : IUnknown
148 void SetParameters(const void *params, UINT32 params_len);
150 void GetParameters(void *params, UINT32 params_len);
153 /* XAudio2 2.7 version of IXAPOParameters is identical to 2.8 */
154 cpp_quote("DEFINE_GUID(IID_IXAPO27Parameters, 0xa90bc001, 0xe897, 0xe897, 0x55, 0xe4, 0x9e, 0x47, 0x00, 0x00, 0x00, 0x01);")