summaryrefslogtreecommitdiff
path: root/platform/windows
diff options
context:
space:
mode:
Diffstat (limited to 'platform/windows')
-rw-r--r--platform/windows/detect.py4
-rw-r--r--platform/windows/os_windows.cpp3
-rw-r--r--platform/windows/os_windows.h4
3 files changed, 10 insertions, 1 deletions
diff --git a/platform/windows/detect.py b/platform/windows/detect.py
index 882e1a808e..d239ccf7d2 100644
--- a/platform/windows/detect.py
+++ b/platform/windows/detect.py
@@ -171,6 +171,7 @@ def configure(env):
env.Append(CCFLAGS=['/DWINDOWS_ENABLED'])
env.Append(CCFLAGS=['/DOPENGL_ENABLED'])
env.Append(CCFLAGS=['/DRTAUDIO_ENABLED'])
+ env.Append(CCFLAGS=['/DWASAPI_ENABLED'])
env.Append(CCFLAGS=['/DTYPED_METHOD_BIND'])
env.Append(CCFLAGS=['/DWIN32'])
env.Append(CCFLAGS=['/DWINVER=%s' % winver, '/D_WIN32_WINNT=%s' % winver])
@@ -252,8 +253,9 @@ def configure(env):
env.Append(CCFLAGS=['-DWINDOWS_ENABLED', '-mwindows'])
env.Append(CCFLAGS=['-DOPENGL_ENABLED'])
env.Append(CCFLAGS=['-DRTAUDIO_ENABLED'])
+ env.Append(CCFLAGS=['-DWASAPI_ENABLED'])
env.Append(CCFLAGS=['-DWINVER=%s' % winver, '-D_WIN32_WINNT=%s' % winver])
- env.Append(LIBS=['mingw32', 'opengl32', 'dsound', 'ole32', 'd3d9', 'winmm', 'gdi32', 'iphlpapi', 'shlwapi', 'wsock32', 'ws2_32', 'kernel32', 'oleaut32', 'dinput8', 'dxguid'])
+ env.Append(LIBS=['mingw32', 'opengl32', 'dsound', 'ole32', 'd3d9', 'winmm', 'gdi32', 'iphlpapi', 'shlwapi', 'wsock32', 'ws2_32', 'kernel32', 'oleaut32', 'dinput8', 'dxguid', 'ksuser'])
env.Append(CPPFLAGS=['-DMINGW_ENABLED'])
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index 7b12482383..deb9c25576 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -2359,6 +2359,9 @@ OS_Windows::OS_Windows(HINSTANCE _hInstance) {
#endif
user_proc = NULL;
+#ifdef WASAPI_ENABLED
+ AudioDriverManager::add_driver(&driver_wasapi);
+#endif
#ifdef RTAUDIO_ENABLED
AudioDriverManager::add_driver(&driver_rtaudio);
#endif
diff --git a/platform/windows/os_windows.h b/platform/windows/os_windows.h
index 01d904a4cc..0c5965bf51 100644
--- a/platform/windows/os_windows.h
+++ b/platform/windows/os_windows.h
@@ -32,6 +32,7 @@
#include "context_gl_win.h"
#include "drivers/rtaudio/audio_driver_rtaudio.h"
+#include "drivers/wasapi/audio_driver_wasapi.h"
#include "os/input.h"
#include "os/os.h"
#include "power_windows.h"
@@ -123,6 +124,9 @@ class OS_Windows : public OS {
PowerWindows *power_manager;
+#ifdef WASAPI_ENABLED
+ AudioDriverWASAPI driver_wasapi;
+#endif
#ifdef RTAUDIO_ENABLED
AudioDriverRtAudio driver_rtaudio;
#endif