]> git.proxmox.com Git - rustc.git/blob - vendor/windows/src/Windows/Win32/Media/Audio/Apo/impl.rs
New upstream version 1.70.0+dfsg1
[rustc.git] / vendor / windows / src / Windows / Win32 / Media / Audio / Apo / impl.rs
1 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
2 pub trait IApoAcousticEchoCancellation_Impl: Sized {}
3 impl ::windows::core::RuntimeName for IApoAcousticEchoCancellation {}
4 impl IApoAcousticEchoCancellation_Vtbl {
5 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAcousticEchoCancellation_Impl, const OFFSET: isize>() -> IApoAcousticEchoCancellation_Vtbl {
6 Self { base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>() }
7 }
8 pub fn matches(iid: &windows::core::GUID) -> bool {
9 iid == &<IApoAcousticEchoCancellation as ::windows::core::ComInterface>::IID
10 }
11 }
12 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
13 pub trait IApoAuxiliaryInputConfiguration_Impl: Sized {
14 fn AddAuxiliaryInput(&self, dwinputid: u32, cbdatasize: u32, pbydata: *const u8, pinputconnection: *const APO_CONNECTION_DESCRIPTOR) -> ::windows::core::Result<()>;
15 fn RemoveAuxiliaryInput(&self, dwinputid: u32) -> ::windows::core::Result<()>;
16 fn IsInputFormatSupported(&self, prequestedinputformat: ::core::option::Option<&IAudioMediaType>) -> ::windows::core::Result<IAudioMediaType>;
17 }
18 impl ::windows::core::RuntimeName for IApoAuxiliaryInputConfiguration {}
19 impl IApoAuxiliaryInputConfiguration_Vtbl {
20 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputConfiguration_Impl, const OFFSET: isize>() -> IApoAuxiliaryInputConfiguration_Vtbl {
21 unsafe extern "system" fn AddAuxiliaryInput<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputConfiguration_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, dwinputid: u32, cbdatasize: u32, pbydata: *const u8, pinputconnection: *const APO_CONNECTION_DESCRIPTOR) -> ::windows::core::HRESULT {
22 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
23 let this = (*this).get_impl();
24 this.AddAuxiliaryInput(::core::mem::transmute_copy(&dwinputid), ::core::mem::transmute_copy(&cbdatasize), ::core::mem::transmute_copy(&pbydata), ::core::mem::transmute_copy(&pinputconnection)).into()
25 }
26 unsafe extern "system" fn RemoveAuxiliaryInput<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputConfiguration_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, dwinputid: u32) -> ::windows::core::HRESULT {
27 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
28 let this = (*this).get_impl();
29 this.RemoveAuxiliaryInput(::core::mem::transmute_copy(&dwinputid)).into()
30 }
31 unsafe extern "system" fn IsInputFormatSupported<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputConfiguration_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, prequestedinputformat: *mut ::core::ffi::c_void, ppsupportedinputformat: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
32 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
33 let this = (*this).get_impl();
34 match this.IsInputFormatSupported(::windows::core::from_raw_borrowed(&prequestedinputformat)) {
35 ::core::result::Result::Ok(ok__) => {
36 ::core::ptr::write(ppsupportedinputformat, ::core::mem::transmute(ok__));
37 ::windows::core::HRESULT(0)
38 }
39 ::core::result::Result::Err(err) => err.into(),
40 }
41 }
42 Self {
43 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
44 AddAuxiliaryInput: AddAuxiliaryInput::<Identity, Impl, OFFSET>,
45 RemoveAuxiliaryInput: RemoveAuxiliaryInput::<Identity, Impl, OFFSET>,
46 IsInputFormatSupported: IsInputFormatSupported::<Identity, Impl, OFFSET>,
47 }
48 }
49 pub fn matches(iid: &windows::core::GUID) -> bool {
50 iid == &<IApoAuxiliaryInputConfiguration as ::windows::core::ComInterface>::IID
51 }
52 }
53 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
54 pub trait IApoAuxiliaryInputRT_Impl: Sized {
55 fn AcceptInput(&self, dwinputid: u32, pinputconnection: *const APO_CONNECTION_PROPERTY);
56 }
57 impl ::windows::core::RuntimeName for IApoAuxiliaryInputRT {}
58 impl IApoAuxiliaryInputRT_Vtbl {
59 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputRT_Impl, const OFFSET: isize>() -> IApoAuxiliaryInputRT_Vtbl {
60 unsafe extern "system" fn AcceptInput<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IApoAuxiliaryInputRT_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, dwinputid: u32, pinputconnection: *const APO_CONNECTION_PROPERTY) {
61 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
62 let this = (*this).get_impl();
63 this.AcceptInput(::core::mem::transmute_copy(&dwinputid), ::core::mem::transmute_copy(&pinputconnection))
64 }
65 Self { base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(), AcceptInput: AcceptInput::<Identity, Impl, OFFSET> }
66 }
67 pub fn matches(iid: &windows::core::GUID) -> bool {
68 iid == &<IApoAuxiliaryInputRT as ::windows::core::ComInterface>::IID
69 }
70 }
71 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
72 pub trait IAudioDeviceModulesClient_Impl: Sized {
73 fn SetAudioDeviceModulesManager(&self, paudiodevicemodulesmanager: ::core::option::Option<&::windows::core::IUnknown>) -> ::windows::core::Result<()>;
74 }
75 impl ::windows::core::RuntimeName for IAudioDeviceModulesClient {}
76 impl IAudioDeviceModulesClient_Vtbl {
77 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioDeviceModulesClient_Impl, const OFFSET: isize>() -> IAudioDeviceModulesClient_Vtbl {
78 unsafe extern "system" fn SetAudioDeviceModulesManager<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioDeviceModulesClient_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, paudiodevicemodulesmanager: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
79 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
80 let this = (*this).get_impl();
81 this.SetAudioDeviceModulesManager(::windows::core::from_raw_borrowed(&paudiodevicemodulesmanager)).into()
82 }
83 Self {
84 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
85 SetAudioDeviceModulesManager: SetAudioDeviceModulesManager::<Identity, Impl, OFFSET>,
86 }
87 }
88 pub fn matches(iid: &windows::core::GUID) -> bool {
89 iid == &<IAudioDeviceModulesClient as ::windows::core::ComInterface>::IID
90 }
91 }
92 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"Win32_Foundation\"`, `\"implement\"`*"]
93 #[cfg(feature = "Win32_Foundation")]
94 pub trait IAudioMediaType_Impl: Sized {
95 fn IsCompressedFormat(&self) -> ::windows::core::Result<super::super::super::Foundation::BOOL>;
96 fn IsEqual(&self, piaudiotype: ::core::option::Option<&IAudioMediaType>) -> ::windows::core::Result<u32>;
97 fn GetAudioFormat(&self) -> *mut super::WAVEFORMATEX;
98 fn GetUncompressedAudioFormat(&self, puncompressedaudioformat: *mut UNCOMPRESSEDAUDIOFORMAT) -> ::windows::core::Result<()>;
99 }
100 #[cfg(feature = "Win32_Foundation")]
101 impl ::windows::core::RuntimeName for IAudioMediaType {}
102 #[cfg(feature = "Win32_Foundation")]
103 impl IAudioMediaType_Vtbl {
104 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioMediaType_Impl, const OFFSET: isize>() -> IAudioMediaType_Vtbl {
105 unsafe extern "system" fn IsCompressedFormat<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioMediaType_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, pfcompressed: *mut super::super::super::Foundation::BOOL) -> ::windows::core::HRESULT {
106 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
107 let this = (*this).get_impl();
108 match this.IsCompressedFormat() {
109 ::core::result::Result::Ok(ok__) => {
110 ::core::ptr::write(pfcompressed, ::core::mem::transmute(ok__));
111 ::windows::core::HRESULT(0)
112 }
113 ::core::result::Result::Err(err) => err.into(),
114 }
115 }
116 unsafe extern "system" fn IsEqual<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioMediaType_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, piaudiotype: *mut ::core::ffi::c_void, pdwflags: *mut u32) -> ::windows::core::HRESULT {
117 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
118 let this = (*this).get_impl();
119 match this.IsEqual(::windows::core::from_raw_borrowed(&piaudiotype)) {
120 ::core::result::Result::Ok(ok__) => {
121 ::core::ptr::write(pdwflags, ::core::mem::transmute(ok__));
122 ::windows::core::HRESULT(0)
123 }
124 ::core::result::Result::Err(err) => err.into(),
125 }
126 }
127 unsafe extern "system" fn GetAudioFormat<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioMediaType_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void) -> *mut super::WAVEFORMATEX {
128 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
129 let this = (*this).get_impl();
130 this.GetAudioFormat()
131 }
132 unsafe extern "system" fn GetUncompressedAudioFormat<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioMediaType_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, puncompressedaudioformat: *mut UNCOMPRESSEDAUDIOFORMAT) -> ::windows::core::HRESULT {
133 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
134 let this = (*this).get_impl();
135 this.GetUncompressedAudioFormat(::core::mem::transmute_copy(&puncompressedaudioformat)).into()
136 }
137 Self {
138 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
139 IsCompressedFormat: IsCompressedFormat::<Identity, Impl, OFFSET>,
140 IsEqual: IsEqual::<Identity, Impl, OFFSET>,
141 GetAudioFormat: GetAudioFormat::<Identity, Impl, OFFSET>,
142 GetUncompressedAudioFormat: GetUncompressedAudioFormat::<Identity, Impl, OFFSET>,
143 }
144 }
145 pub fn matches(iid: &windows::core::GUID) -> bool {
146 iid == &<IAudioMediaType as ::windows::core::ComInterface>::IID
147 }
148 }
149 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
150 pub trait IAudioProcessingObject_Impl: Sized {
151 fn Reset(&self) -> ::windows::core::Result<()>;
152 fn GetLatency(&self) -> ::windows::core::Result<i64>;
153 fn GetRegistrationProperties(&self) -> ::windows::core::Result<*mut APO_REG_PROPERTIES>;
154 fn Initialize(&self, cbdatasize: u32, pbydata: *const u8) -> ::windows::core::Result<()>;
155 fn IsInputFormatSupported(&self, poppositeformat: ::core::option::Option<&IAudioMediaType>, prequestedinputformat: ::core::option::Option<&IAudioMediaType>) -> ::windows::core::Result<IAudioMediaType>;
156 fn IsOutputFormatSupported(&self, poppositeformat: ::core::option::Option<&IAudioMediaType>, prequestedoutputformat: ::core::option::Option<&IAudioMediaType>) -> ::windows::core::Result<IAudioMediaType>;
157 fn GetInputChannelCount(&self) -> ::windows::core::Result<u32>;
158 }
159 impl ::windows::core::RuntimeName for IAudioProcessingObject {}
160 impl IAudioProcessingObject_Vtbl {
161 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>() -> IAudioProcessingObject_Vtbl {
162 unsafe extern "system" fn Reset<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
163 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
164 let this = (*this).get_impl();
165 this.Reset().into()
166 }
167 unsafe extern "system" fn GetLatency<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, ptime: *mut i64) -> ::windows::core::HRESULT {
168 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
169 let this = (*this).get_impl();
170 match this.GetLatency() {
171 ::core::result::Result::Ok(ok__) => {
172 ::core::ptr::write(ptime, ::core::mem::transmute(ok__));
173 ::windows::core::HRESULT(0)
174 }
175 ::core::result::Result::Err(err) => err.into(),
176 }
177 }
178 unsafe extern "system" fn GetRegistrationProperties<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, ppregprops: *mut *mut APO_REG_PROPERTIES) -> ::windows::core::HRESULT {
179 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
180 let this = (*this).get_impl();
181 match this.GetRegistrationProperties() {
182 ::core::result::Result::Ok(ok__) => {
183 ::core::ptr::write(ppregprops, ::core::mem::transmute(ok__));
184 ::windows::core::HRESULT(0)
185 }
186 ::core::result::Result::Err(err) => err.into(),
187 }
188 }
189 unsafe extern "system" fn Initialize<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, cbdatasize: u32, pbydata: *const u8) -> ::windows::core::HRESULT {
190 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
191 let this = (*this).get_impl();
192 this.Initialize(::core::mem::transmute_copy(&cbdatasize), ::core::mem::transmute_copy(&pbydata)).into()
193 }
194 unsafe extern "system" fn IsInputFormatSupported<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, poppositeformat: *mut ::core::ffi::c_void, prequestedinputformat: *mut ::core::ffi::c_void, ppsupportedinputformat: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
195 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
196 let this = (*this).get_impl();
197 match this.IsInputFormatSupported(::windows::core::from_raw_borrowed(&poppositeformat), ::windows::core::from_raw_borrowed(&prequestedinputformat)) {
198 ::core::result::Result::Ok(ok__) => {
199 ::core::ptr::write(ppsupportedinputformat, ::core::mem::transmute(ok__));
200 ::windows::core::HRESULT(0)
201 }
202 ::core::result::Result::Err(err) => err.into(),
203 }
204 }
205 unsafe extern "system" fn IsOutputFormatSupported<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, poppositeformat: *mut ::core::ffi::c_void, prequestedoutputformat: *mut ::core::ffi::c_void, ppsupportedoutputformat: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
206 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
207 let this = (*this).get_impl();
208 match this.IsOutputFormatSupported(::windows::core::from_raw_borrowed(&poppositeformat), ::windows::core::from_raw_borrowed(&prequestedoutputformat)) {
209 ::core::result::Result::Ok(ok__) => {
210 ::core::ptr::write(ppsupportedoutputformat, ::core::mem::transmute(ok__));
211 ::windows::core::HRESULT(0)
212 }
213 ::core::result::Result::Err(err) => err.into(),
214 }
215 }
216 unsafe extern "system" fn GetInputChannelCount<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObject_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, pu32channelcount: *mut u32) -> ::windows::core::HRESULT {
217 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
218 let this = (*this).get_impl();
219 match this.GetInputChannelCount() {
220 ::core::result::Result::Ok(ok__) => {
221 ::core::ptr::write(pu32channelcount, ::core::mem::transmute(ok__));
222 ::windows::core::HRESULT(0)
223 }
224 ::core::result::Result::Err(err) => err.into(),
225 }
226 }
227 Self {
228 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
229 Reset: Reset::<Identity, Impl, OFFSET>,
230 GetLatency: GetLatency::<Identity, Impl, OFFSET>,
231 GetRegistrationProperties: GetRegistrationProperties::<Identity, Impl, OFFSET>,
232 Initialize: Initialize::<Identity, Impl, OFFSET>,
233 IsInputFormatSupported: IsInputFormatSupported::<Identity, Impl, OFFSET>,
234 IsOutputFormatSupported: IsOutputFormatSupported::<Identity, Impl, OFFSET>,
235 GetInputChannelCount: GetInputChannelCount::<Identity, Impl, OFFSET>,
236 }
237 }
238 pub fn matches(iid: &windows::core::GUID) -> bool {
239 iid == &<IAudioProcessingObject as ::windows::core::ComInterface>::IID
240 }
241 }
242 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
243 pub trait IAudioProcessingObjectConfiguration_Impl: Sized {
244 fn LockForProcess(&self, u32numinputconnections: u32, ppinputconnections: *const *const APO_CONNECTION_DESCRIPTOR, u32numoutputconnections: u32, ppoutputconnections: *const *const APO_CONNECTION_DESCRIPTOR) -> ::windows::core::Result<()>;
245 fn UnlockForProcess(&self) -> ::windows::core::Result<()>;
246 }
247 impl ::windows::core::RuntimeName for IAudioProcessingObjectConfiguration {}
248 impl IAudioProcessingObjectConfiguration_Vtbl {
249 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectConfiguration_Impl, const OFFSET: isize>() -> IAudioProcessingObjectConfiguration_Vtbl {
250 unsafe extern "system" fn LockForProcess<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectConfiguration_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32numinputconnections: u32, ppinputconnections: *const *const APO_CONNECTION_DESCRIPTOR, u32numoutputconnections: u32, ppoutputconnections: *const *const APO_CONNECTION_DESCRIPTOR) -> ::windows::core::HRESULT {
251 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
252 let this = (*this).get_impl();
253 this.LockForProcess(::core::mem::transmute_copy(&u32numinputconnections), ::core::mem::transmute_copy(&ppinputconnections), ::core::mem::transmute_copy(&u32numoutputconnections), ::core::mem::transmute_copy(&ppoutputconnections)).into()
254 }
255 unsafe extern "system" fn UnlockForProcess<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectConfiguration_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
256 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
257 let this = (*this).get_impl();
258 this.UnlockForProcess().into()
259 }
260 Self {
261 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
262 LockForProcess: LockForProcess::<Identity, Impl, OFFSET>,
263 UnlockForProcess: UnlockForProcess::<Identity, Impl, OFFSET>,
264 }
265 }
266 pub fn matches(iid: &windows::core::GUID) -> bool {
267 iid == &<IAudioProcessingObjectConfiguration as ::windows::core::ComInterface>::IID
268 }
269 }
270 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
271 pub trait IAudioProcessingObjectLoggingService_Impl: Sized {
272 fn ApoLog(&self, level: APO_LOG_LEVEL, format: &::windows::core::PCWSTR);
273 }
274 impl ::windows::core::RuntimeName for IAudioProcessingObjectLoggingService {}
275 impl IAudioProcessingObjectLoggingService_Vtbl {
276 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectLoggingService_Impl, const OFFSET: isize>() -> IAudioProcessingObjectLoggingService_Vtbl {
277 unsafe extern "system" fn ApoLog<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectLoggingService_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, level: APO_LOG_LEVEL, format: ::windows::core::PCWSTR) {
278 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
279 let this = (*this).get_impl();
280 this.ApoLog(::core::mem::transmute_copy(&level), ::core::mem::transmute(&format))
281 }
282 Self { base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(), ApoLog: ApoLog::<Identity, Impl, OFFSET> }
283 }
284 pub fn matches(iid: &windows::core::GUID) -> bool {
285 iid == &<IAudioProcessingObjectLoggingService as ::windows::core::ComInterface>::IID
286 }
287 }
288 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"Win32_Foundation\"`, `\"Win32_UI_Shell_PropertiesSystem\"`, `\"implement\"`*"]
289 #[cfg(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem"))]
290 pub trait IAudioProcessingObjectNotifications_Impl: Sized {
291 fn GetApoNotificationRegistrationInfo(&self, aponotifications: *mut *mut APO_NOTIFICATION_DESCRIPTOR, count: *mut u32) -> ::windows::core::Result<()>;
292 fn HandleNotification(&self, aponotification: *const APO_NOTIFICATION);
293 }
294 #[cfg(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem"))]
295 impl ::windows::core::RuntimeName for IAudioProcessingObjectNotifications {}
296 #[cfg(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem"))]
297 impl IAudioProcessingObjectNotifications_Vtbl {
298 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectNotifications_Impl, const OFFSET: isize>() -> IAudioProcessingObjectNotifications_Vtbl {
299 unsafe extern "system" fn GetApoNotificationRegistrationInfo<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectNotifications_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, aponotifications: *mut *mut APO_NOTIFICATION_DESCRIPTOR, count: *mut u32) -> ::windows::core::HRESULT {
300 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
301 let this = (*this).get_impl();
302 this.GetApoNotificationRegistrationInfo(::core::mem::transmute_copy(&aponotifications), ::core::mem::transmute_copy(&count)).into()
303 }
304 unsafe extern "system" fn HandleNotification<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectNotifications_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, aponotification: *const APO_NOTIFICATION) {
305 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
306 let this = (*this).get_impl();
307 this.HandleNotification(::core::mem::transmute_copy(&aponotification))
308 }
309 Self {
310 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
311 GetApoNotificationRegistrationInfo: GetApoNotificationRegistrationInfo::<Identity, Impl, OFFSET>,
312 HandleNotification: HandleNotification::<Identity, Impl, OFFSET>,
313 }
314 }
315 pub fn matches(iid: &windows::core::GUID) -> bool {
316 iid == &<IAudioProcessingObjectNotifications as ::windows::core::ComInterface>::IID
317 }
318 }
319 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
320 pub trait IAudioProcessingObjectRT_Impl: Sized {
321 fn APOProcess(&self, u32numinputconnections: u32, ppinputconnections: *const *const APO_CONNECTION_PROPERTY, u32numoutputconnections: u32, ppoutputconnections: *mut *mut APO_CONNECTION_PROPERTY);
322 fn CalcInputFrames(&self, u32outputframecount: u32) -> u32;
323 fn CalcOutputFrames(&self, u32inputframecount: u32) -> u32;
324 }
325 impl ::windows::core::RuntimeName for IAudioProcessingObjectRT {}
326 impl IAudioProcessingObjectRT_Vtbl {
327 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRT_Impl, const OFFSET: isize>() -> IAudioProcessingObjectRT_Vtbl {
328 unsafe extern "system" fn APOProcess<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRT_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32numinputconnections: u32, ppinputconnections: *const *const APO_CONNECTION_PROPERTY, u32numoutputconnections: u32, ppoutputconnections: *mut *mut APO_CONNECTION_PROPERTY) {
329 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
330 let this = (*this).get_impl();
331 this.APOProcess(::core::mem::transmute_copy(&u32numinputconnections), ::core::mem::transmute_copy(&ppinputconnections), ::core::mem::transmute_copy(&u32numoutputconnections), ::core::mem::transmute_copy(&ppoutputconnections))
332 }
333 unsafe extern "system" fn CalcInputFrames<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRT_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32outputframecount: u32) -> u32 {
334 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
335 let this = (*this).get_impl();
336 this.CalcInputFrames(::core::mem::transmute_copy(&u32outputframecount))
337 }
338 unsafe extern "system" fn CalcOutputFrames<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRT_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32inputframecount: u32) -> u32 {
339 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
340 let this = (*this).get_impl();
341 this.CalcOutputFrames(::core::mem::transmute_copy(&u32inputframecount))
342 }
343 Self {
344 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
345 APOProcess: APOProcess::<Identity, Impl, OFFSET>,
346 CalcInputFrames: CalcInputFrames::<Identity, Impl, OFFSET>,
347 CalcOutputFrames: CalcOutputFrames::<Identity, Impl, OFFSET>,
348 }
349 }
350 pub fn matches(iid: &windows::core::GUID) -> bool {
351 iid == &<IAudioProcessingObjectRT as ::windows::core::ComInterface>::IID
352 }
353 }
354 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
355 pub trait IAudioProcessingObjectRTQueueService_Impl: Sized {
356 fn GetRealTimeWorkQueue(&self) -> ::windows::core::Result<u32>;
357 }
358 impl ::windows::core::RuntimeName for IAudioProcessingObjectRTQueueService {}
359 impl IAudioProcessingObjectRTQueueService_Vtbl {
360 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRTQueueService_Impl, const OFFSET: isize>() -> IAudioProcessingObjectRTQueueService_Vtbl {
361 unsafe extern "system" fn GetRealTimeWorkQueue<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectRTQueueService_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, workqueueid: *mut u32) -> ::windows::core::HRESULT {
362 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
363 let this = (*this).get_impl();
364 match this.GetRealTimeWorkQueue() {
365 ::core::result::Result::Ok(ok__) => {
366 ::core::ptr::write(workqueueid, ::core::mem::transmute(ok__));
367 ::windows::core::HRESULT(0)
368 }
369 ::core::result::Result::Err(err) => err.into(),
370 }
371 }
372 Self { base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(), GetRealTimeWorkQueue: GetRealTimeWorkQueue::<Identity, Impl, OFFSET> }
373 }
374 pub fn matches(iid: &windows::core::GUID) -> bool {
375 iid == &<IAudioProcessingObjectRTQueueService as ::windows::core::ComInterface>::IID
376 }
377 }
378 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
379 pub trait IAudioProcessingObjectVBR_Impl: Sized {
380 fn CalcMaxInputFrames(&self, u32maxoutputframecount: u32) -> ::windows::core::Result<u32>;
381 fn CalcMaxOutputFrames(&self, u32maxinputframecount: u32) -> ::windows::core::Result<u32>;
382 }
383 impl ::windows::core::RuntimeName for IAudioProcessingObjectVBR {}
384 impl IAudioProcessingObjectVBR_Vtbl {
385 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectVBR_Impl, const OFFSET: isize>() -> IAudioProcessingObjectVBR_Vtbl {
386 unsafe extern "system" fn CalcMaxInputFrames<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectVBR_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32maxoutputframecount: u32, pu32inputframecount: *mut u32) -> ::windows::core::HRESULT {
387 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
388 let this = (*this).get_impl();
389 match this.CalcMaxInputFrames(::core::mem::transmute_copy(&u32maxoutputframecount)) {
390 ::core::result::Result::Ok(ok__) => {
391 ::core::ptr::write(pu32inputframecount, ::core::mem::transmute(ok__));
392 ::windows::core::HRESULT(0)
393 }
394 ::core::result::Result::Err(err) => err.into(),
395 }
396 }
397 unsafe extern "system" fn CalcMaxOutputFrames<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioProcessingObjectVBR_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, u32maxinputframecount: u32, pu32outputframecount: *mut u32) -> ::windows::core::HRESULT {
398 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
399 let this = (*this).get_impl();
400 match this.CalcMaxOutputFrames(::core::mem::transmute_copy(&u32maxinputframecount)) {
401 ::core::result::Result::Ok(ok__) => {
402 ::core::ptr::write(pu32outputframecount, ::core::mem::transmute(ok__));
403 ::windows::core::HRESULT(0)
404 }
405 ::core::result::Result::Err(err) => err.into(),
406 }
407 }
408 Self {
409 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
410 CalcMaxInputFrames: CalcMaxInputFrames::<Identity, Impl, OFFSET>,
411 CalcMaxOutputFrames: CalcMaxOutputFrames::<Identity, Impl, OFFSET>,
412 }
413 }
414 pub fn matches(iid: &windows::core::GUID) -> bool {
415 iid == &<IAudioProcessingObjectVBR as ::windows::core::ComInterface>::IID
416 }
417 }
418 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
419 pub trait IAudioSystemEffects_Impl: Sized {}
420 impl ::windows::core::RuntimeName for IAudioSystemEffects {}
421 impl IAudioSystemEffects_Vtbl {
422 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects_Impl, const OFFSET: isize>() -> IAudioSystemEffects_Vtbl {
423 Self { base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>() }
424 }
425 pub fn matches(iid: &windows::core::GUID) -> bool {
426 iid == &<IAudioSystemEffects as ::windows::core::ComInterface>::IID
427 }
428 }
429 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"Win32_Foundation\"`, `\"implement\"`*"]
430 #[cfg(feature = "Win32_Foundation")]
431 pub trait IAudioSystemEffects2_Impl: Sized + IAudioSystemEffects_Impl {
432 fn GetEffectsList(&self, ppeffectsids: *mut *mut ::windows::core::GUID, pceffects: *mut u32, event: super::super::super::Foundation::HANDLE) -> ::windows::core::Result<()>;
433 }
434 #[cfg(feature = "Win32_Foundation")]
435 impl ::windows::core::RuntimeName for IAudioSystemEffects2 {}
436 #[cfg(feature = "Win32_Foundation")]
437 impl IAudioSystemEffects2_Vtbl {
438 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects2_Impl, const OFFSET: isize>() -> IAudioSystemEffects2_Vtbl {
439 unsafe extern "system" fn GetEffectsList<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects2_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, ppeffectsids: *mut *mut ::windows::core::GUID, pceffects: *mut u32, event: super::super::super::Foundation::HANDLE) -> ::windows::core::HRESULT {
440 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
441 let this = (*this).get_impl();
442 this.GetEffectsList(::core::mem::transmute_copy(&ppeffectsids), ::core::mem::transmute_copy(&pceffects), ::core::mem::transmute_copy(&event)).into()
443 }
444 Self { base__: IAudioSystemEffects_Vtbl::new::<Identity, Impl, OFFSET>(), GetEffectsList: GetEffectsList::<Identity, Impl, OFFSET> }
445 }
446 pub fn matches(iid: &windows::core::GUID) -> bool {
447 iid == &<IAudioSystemEffects2 as ::windows::core::ComInterface>::IID || iid == &<IAudioSystemEffects as ::windows::core::ComInterface>::IID
448 }
449 }
450 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"Win32_Foundation\"`, `\"implement\"`*"]
451 #[cfg(feature = "Win32_Foundation")]
452 pub trait IAudioSystemEffects3_Impl: Sized + IAudioSystemEffects2_Impl {
453 fn GetControllableSystemEffectsList(&self, effects: *mut *mut AUDIO_SYSTEMEFFECT, numeffects: *mut u32, event: super::super::super::Foundation::HANDLE) -> ::windows::core::Result<()>;
454 fn SetAudioSystemEffectState(&self, effectid: &::windows::core::GUID, state: AUDIO_SYSTEMEFFECT_STATE) -> ::windows::core::Result<()>;
455 }
456 #[cfg(feature = "Win32_Foundation")]
457 impl ::windows::core::RuntimeName for IAudioSystemEffects3 {}
458 #[cfg(feature = "Win32_Foundation")]
459 impl IAudioSystemEffects3_Vtbl {
460 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects3_Impl, const OFFSET: isize>() -> IAudioSystemEffects3_Vtbl {
461 unsafe extern "system" fn GetControllableSystemEffectsList<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects3_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, effects: *mut *mut AUDIO_SYSTEMEFFECT, numeffects: *mut u32, event: super::super::super::Foundation::HANDLE) -> ::windows::core::HRESULT {
462 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
463 let this = (*this).get_impl();
464 this.GetControllableSystemEffectsList(::core::mem::transmute_copy(&effects), ::core::mem::transmute_copy(&numeffects), ::core::mem::transmute_copy(&event)).into()
465 }
466 unsafe extern "system" fn SetAudioSystemEffectState<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffects3_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, effectid: ::windows::core::GUID, state: AUDIO_SYSTEMEFFECT_STATE) -> ::windows::core::HRESULT {
467 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
468 let this = (*this).get_impl();
469 this.SetAudioSystemEffectState(::core::mem::transmute(&effectid), ::core::mem::transmute_copy(&state)).into()
470 }
471 Self {
472 base__: IAudioSystemEffects2_Vtbl::new::<Identity, Impl, OFFSET>(),
473 GetControllableSystemEffectsList: GetControllableSystemEffectsList::<Identity, Impl, OFFSET>,
474 SetAudioSystemEffectState: SetAudioSystemEffectState::<Identity, Impl, OFFSET>,
475 }
476 }
477 pub fn matches(iid: &windows::core::GUID) -> bool {
478 iid == &<IAudioSystemEffects3 as ::windows::core::ComInterface>::IID || iid == &<IAudioSystemEffects as ::windows::core::ComInterface>::IID || iid == &<IAudioSystemEffects2 as ::windows::core::ComInterface>::IID
479 }
480 }
481 #[doc = "*Required features: `\"Win32_Media_Audio_Apo\"`, `\"implement\"`*"]
482 pub trait IAudioSystemEffectsCustomFormats_Impl: Sized {
483 fn GetFormatCount(&self) -> ::windows::core::Result<u32>;
484 fn GetFormat(&self, nformat: u32) -> ::windows::core::Result<IAudioMediaType>;
485 fn GetFormatRepresentation(&self, nformat: u32) -> ::windows::core::Result<::windows::core::PWSTR>;
486 }
487 impl ::windows::core::RuntimeName for IAudioSystemEffectsCustomFormats {}
488 impl IAudioSystemEffectsCustomFormats_Vtbl {
489 pub const fn new<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffectsCustomFormats_Impl, const OFFSET: isize>() -> IAudioSystemEffectsCustomFormats_Vtbl {
490 unsafe extern "system" fn GetFormatCount<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffectsCustomFormats_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, pcformats: *mut u32) -> ::windows::core::HRESULT {
491 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
492 let this = (*this).get_impl();
493 match this.GetFormatCount() {
494 ::core::result::Result::Ok(ok__) => {
495 ::core::ptr::write(pcformats, ::core::mem::transmute(ok__));
496 ::windows::core::HRESULT(0)
497 }
498 ::core::result::Result::Err(err) => err.into(),
499 }
500 }
501 unsafe extern "system" fn GetFormat<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffectsCustomFormats_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, nformat: u32, ppformat: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
502 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
503 let this = (*this).get_impl();
504 match this.GetFormat(::core::mem::transmute_copy(&nformat)) {
505 ::core::result::Result::Ok(ok__) => {
506 ::core::ptr::write(ppformat, ::core::mem::transmute(ok__));
507 ::windows::core::HRESULT(0)
508 }
509 ::core::result::Result::Err(err) => err.into(),
510 }
511 }
512 unsafe extern "system" fn GetFormatRepresentation<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IAudioSystemEffectsCustomFormats_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, nformat: u32, ppwstrformatrep: *mut ::windows::core::PWSTR) -> ::windows::core::HRESULT {
513 let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
514 let this = (*this).get_impl();
515 match this.GetFormatRepresentation(::core::mem::transmute_copy(&nformat)) {
516 ::core::result::Result::Ok(ok__) => {
517 ::core::ptr::write(ppwstrformatrep, ::core::mem::transmute(ok__));
518 ::windows::core::HRESULT(0)
519 }
520 ::core::result::Result::Err(err) => err.into(),
521 }
522 }
523 Self {
524 base__: ::windows::core::IUnknown_Vtbl::new::<Identity, OFFSET>(),
525 GetFormatCount: GetFormatCount::<Identity, Impl, OFFSET>,
526 GetFormat: GetFormat::<Identity, Impl, OFFSET>,
527 GetFormatRepresentation: GetFormatRepresentation::<Identity, Impl, OFFSET>,
528 }
529 }
530 pub fn matches(iid: &windows::core::GUID) -> bool {
531 iid == &<IAudioSystemEffectsCustomFormats as ::windows::core::ComInterface>::IID
532 }
533 }