[PATCH 3/3] mmdevapi: copy ContainerID from audio driver if available

Claire Girka wine at gitlab.winehq.org
Sat Jul 2 04:53:47 CDT 2022


From: Claire Girka <claire at sitedethib.com>

Some games with support for the haptic feedback and speaker features of the
Sony DualSense controller select the controller's audio output by filtering on
the ContainerId IMMDevice property to find one that matches the controller's
HID's.
---
 dlls/mmdevapi/devenum.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/dlls/mmdevapi/devenum.c b/dlls/mmdevapi/devenum.c
index 0ffd4fd1ad7..9f95930c308 100644
--- a/dlls/mmdevapi/devenum.c
+++ b/dlls/mmdevapi/devenum.c
@@ -375,6 +375,8 @@ static MMDevice *MMDevice_Create(WCHAR *name, GUID *id, EDataFlow flow, DWORD st
             MMDevice_SetPropValue(id, flow, (const PROPERTYKEY*)&DEVPKEY_DeviceInterface_FriendlyName, &pv);
             MMDevice_SetPropValue(id, flow, (const PROPERTYKEY*)&DEVPKEY_Device_DeviceDesc, &pv);
 
+            set_driver_prop_value(id, flow, (const PROPERTYKEY*)&DEVPKEY_Device_ContainerId);
+
             pv.pwszVal = guidstr;
             MMDevice_SetPropValue(id, flow, &deviceinterface_key, &pv);
 
-- 
GitLab

https://gitlab.winehq.org/wine/wine/-/merge_requests/359



More information about the wine-devel mailing list