39 lines
1.9 KiB
C
39 lines
1.9 KiB
C
#ifndef _IAUDIOSESSIONEVENTS_H_
|
|
#define _IAUDIOSESSIONEVENTS_H_
|
|
|
|
#include <combaseapi.h>
|
|
#include <audiopolicy.h>
|
|
#include <stdio.h>
|
|
#include <Windows.h>
|
|
|
|
#ifndef __myIAudioSessionEvents_FWD_DEFINED__
|
|
#define __myIAudioSessionEvents_FWD_DEFINED__
|
|
typedef interface myIAudioSessionEvents myIAudioSessionEvents;
|
|
|
|
#endif /* __myIAudioSessionEvents_FWD_DEFINED__ */
|
|
|
|
HRESULT InitializeAudioSessionEvents(myIAudioSessionEvents **, IAudioSessionControl *, IAudioSessionControl ***);
|
|
|
|
HRESULT STDMETHODCALLTYPE IAudioSessionEventsQueryInterface(IAudioSessionEvents*, REFIID, void**);
|
|
ULONG STDMETHODCALLTYPE IAudioSessionEventsAddRef(IAudioSessionEvents*);
|
|
ULONG STDMETHODCALLTYPE IAudioSessionEventsRelease(IAudioSessionEvents*);
|
|
HRESULT IAudioSessionEventsOnChannelVolumeChanged(IAudioSessionEvents*, DWORD, float*,DWORD, LPCGUID);
|
|
HRESULT IAudioSessionEventsOnDisplayNameChanged(IAudioSessionEvents*, LPCWSTR, LPCGUID);
|
|
HRESULT IAudioSessionEventsOnGroupingParamChanged(IAudioSessionEvents*, LPCGUID, LPCGUID);
|
|
HRESULT IAudioSessionEventsOnIconPathChanged(IAudioSessionEvents*, LPCWSTR, LPCGUID);
|
|
HRESULT IAudioSessionEventsOnSessionDisconnected(IAudioSessionEvents*, AudioSessionDisconnectReason);
|
|
HRESULT IAudioSessionEventsOnSimpleVolumeChanged(IAudioSessionEvents*, float, BOOL, LPCGUID);
|
|
HRESULT IAudioSessionEventsOnStateChanged(IAudioSessionEvents*, AudioSessionState);
|
|
|
|
|
|
interface myIAudioSessionEvents {
|
|
CONST_VTBL struct IAudioSessionEventsVtbl* lpVtbl;
|
|
ULONG cRef;
|
|
// This is an extension to the standard interface and will be used to keep track of the IAudioSessionControl interface which created it
|
|
IAudioSessionControl* pParentAudioSessionControl;
|
|
// This is the address of the pointer which points to the array of control interface pointers
|
|
// This constant as far as this interface is concerned but is required for finding the array of interfaces on session destruction
|
|
IAudioSessionControl*** pControlInterfaceArrayAddress;
|
|
};
|
|
|
|
#endif |