From a6bf38bcadafd3f7b08b63d8ea1642a9f351f6e6 Mon Sep 17 00:00:00 2001 From: Kevin Mitchell Date: Tue, 31 Mar 2015 01:56:17 -0700 Subject: ao/wasapi: add ao hotplug Create a second copy of the change_notify structure for the hotplug ao. change_notify->is_hotplug distinguishes the hotplug version from the regular one monitoring the currently playing ao. Also make the change notification less verbose now that there might be two of them around. --- audio/out/ao_wasapi.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'audio/out/ao_wasapi.h') diff --git a/audio/out/ao_wasapi.h b/audio/out/ao_wasapi.h index 2fd266eab0..3ae0816a8d 100755 --- a/audio/out/ao_wasapi.h +++ b/audio/out/ao_wasapi.h @@ -20,6 +20,7 @@ #ifndef MP_AO_WASAPI_H_ #define MP_AO_WASAPI_H_ +#include #include #include #include @@ -30,10 +31,11 @@ typedef struct change_notify { IMMNotificationClient client; /* this must be first in the structure! */ LPWSTR monitored; /* Monitored device */ + bool is_hotplug; struct ao *ao; } change_notify; -HRESULT wasapi_change_init(struct ao* ao); +HRESULT wasapi_change_init(struct ao* ao, bool is_hotplug); void wasapi_change_uninit(struct ao* ao); #define EXIT_ON_ERROR(hres) \ -- cgit v1.2.3