wineoss: Export function to get AudioSessionWrapper object.

This commit is contained in:
Davide Beatrici 2023-04-12 09:33:28 +02:00 committed by Alexandre Julliard
parent 0e7a4fd7c1
commit 07d6a48c73
2 changed files with 19 additions and 0 deletions

View file

@ -2321,3 +2321,21 @@ HRESULT WINAPI AUDDRV_GetAudioSessionManager(IMMDevice *device,
return S_OK;
}
HRESULT WINAPI AUDDRV_GetAudioSessionWrapper(const GUID *guid, IMMDevice *device,
AudioSessionWrapper **out)
{
AudioSession *session;
HRESULT hr = get_audio_session(guid, device, 0, &session);
if(FAILED(hr))
return hr;
*out = AudioSessionWrapper_Create(NULL);
if(!*out)
return E_OUTOFMEMORY;
(*out)->session = session;
return S_OK;
}

View file

@ -8,3 +8,4 @@
@ stdcall -private GetEndpointIDs(long ptr ptr ptr ptr) AUDDRV_GetEndpointIDs
@ stdcall -private GetAudioEndpoint(ptr ptr ptr) AUDDRV_GetAudioEndpoint
@ stdcall -private GetAudioSessionManager(ptr ptr) AUDDRV_GetAudioSessionManager
@ stdcall -private GetAudioSessionWrapper(ptr ptr ptr) AUDDRV_GetAudioSessionWrapper