Commit Graph

13 Commits

Author SHA1 Message Date
Kevin Mitchell 4987c1906d ao_wasapi: abstract HRESULT_to_str 2015-04-01 02:30:19 -07:00
Kevin Mitchell e408dd20c7 ao_wasapi: remove redundant casts 2015-03-31 14:13:58 -07:00
Kevin Mitchell a6bf38bcad 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.
2015-03-31 02:02:54 -07:00
Kevin Mitchell 81da34549f ao/wasapi: add missing "if" braces 2015-03-26 05:52:34 -07:00
wm4 f61b8b312d win32: request UTF-16 API variants, Vista+ APIs, and COM C macros
Put the Vista+ (_WIN32_WINNT) and the COM C (COBJMACROS) defines into
the build system, instead of defining them over and over in the code.
2015-01-07 21:42:44 +01:00
Kevin Mitchell 6a6620a554 ao/wasapi: style/code formatting tweaks 2015-01-02 14:50:59 -08:00
Kevin Mitchell 1e5f9d2673 ao/wasapi: use IsEqualGUID and IsEqualPropertyKey
before we were reinventing this wheel
2014-12-16 03:29:51 -08:00
Kevin Mitchell 239c880fe2 ao/wasapi: expose GUID and PKEY convenience functions
Give them the prefix mp_ and make them nonstatic.
2014-11-28 10:48:36 -08:00
Kevin Mitchell 94ea4435a9 ao/wasapi: refix printf warning for both cygwin and msys
a cast to (unsigned) should do "the right thing".
2014-11-18 05:03:33 -08:00
James Ross-Gowan d9bac96a9d ao/wasapi: silence format string warnings 2014-11-18 12:19:36 +11:00
Kevin Mitchell 6c512892d4 ao/wasapi: request reset on appropriate events
on changes to PKEY_AudioEngine_DeviceFormat, device status, and default device.
call ao_reload directly in the change_notify "methods".

this requires keeping a device enumerator around for the duration of
execution, rather than just for initially querying devices
2014-11-17 04:31:20 -08:00
Kevin Mitchell e647f202ed ao/wasapi: add convenience functions for change notifiy 2014-11-17 04:30:53 -08:00
Jonathan Yong f29f16663a ao/wasapi: new wasapi device monitoring interface
Implement skeleton IMMNotificationClient to watch for changes in the
sound device.  This will make recovery possible from changes shared
mode sample rate, bit depth, "enhancements"/effects and even graceful
device removal.

http://msdn.microsoft.com/en-us/library/windows/desktop/dd371417%28v=vs.85%29.aspx

Signed-off-by: Kevin Mitchell <kevmitch@gmail.com>
2014-11-17 04:30:53 -08:00