From 3d3e4ec1ba7ad8bad3074338ee44f12fb9acb8a4 Mon Sep 17 00:00:00 2001 From: GovanifY Date: Sat, 26 Sep 2020 12:56:51 +0200 Subject: [PATCH] SPU2: enabling portaudio on windows --- pcsx2/SPU2/SndOut_Portaudio.cpp | 8 +++++--- pcsx2/windows/VCprojects/pcsx2.vcxproj | 7 +++++++ pcsx2/windows/VCprojects/pcsx2.vcxproj.filters | 3 +++ 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/pcsx2/SPU2/SndOut_Portaudio.cpp b/pcsx2/SPU2/SndOut_Portaudio.cpp index 8417f52979..74cab3a3a7 100644 --- a/pcsx2/SPU2/SndOut_Portaudio.cpp +++ b/pcsx2/SPU2/SndOut_Portaudio.cpp @@ -14,18 +14,20 @@ */ #include "PrecompiledHeader.h" -#include "Mixer.h" +//#include "Mixer.h" #include "Global.h" #include "SndOut.h" #define _WIN32_DCOM #ifdef _WIN32 +#include #include "Windows/Dialogs.h" #elif defined __linux +#include "portaudio.h" #include "Linux/Dialogs.h" #endif -#include "portaudio.h" + #include "wchar.h" @@ -556,7 +558,7 @@ public: // keep portaudio initialized until the dialog closes INT_PTR ret; - ret = DialogBoxParam(hInstance, MAKEINTRESOURCE(IDD_PORTAUDIO), (HWND)parent, (DLGPROC)ConfigProc, 1); + ret = DialogBoxParam(nullptr, MAKEINTRESOURCE(IDD_PORTAUDIO), (HWND)parent, (DLGPROC)ConfigProc, 1); if (ret == -1) { MessageBox((HWND)parent, L"Error Opening the config dialog.", L"OMG ERROR!", MB_OK | MB_SETFOREGROUND); diff --git a/pcsx2/windows/VCprojects/pcsx2.vcxproj b/pcsx2/windows/VCprojects/pcsx2.vcxproj index 2b2b7cc8f3..8e4dd1c6aa 100644 --- a/pcsx2/windows/VCprojects/pcsx2.vcxproj +++ b/pcsx2/windows/VCprojects/pcsx2.vcxproj @@ -62,6 +62,12 @@ Use PrecompiledHeader.h NoExtensions + PCSX2_DEBUG;PCSX2_DEVBUILD;_SECURE_SCL_=1;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) + PCSX2_DEVEL;PCSX2_DEVBUILD;NDEBUG;_SECURE_SCL_=1;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) + NDEBUG;_SECURE_SCL_=0;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) + NDEBUG;_SECURE_SCL_=0;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) + PCSX2_DEVEL;PCSX2_DEVBUILD;NDEBUG;_SECURE_SCL_=1;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) + PCSX2_DEBUG;PCSX2_DEVBUILD;_SECURE_SCL_=1;SPU2X_PORTAUDIO;%(PreprocessorDefinitions) Yes @@ -276,6 +282,7 @@ + diff --git a/pcsx2/windows/VCprojects/pcsx2.vcxproj.filters b/pcsx2/windows/VCprojects/pcsx2.vcxproj.filters index 65bba06e20..eddf75dbfa 100644 --- a/pcsx2/windows/VCprojects/pcsx2.vcxproj.filters +++ b/pcsx2/windows/VCprojects/pcsx2.vcxproj.filters @@ -997,6 +997,9 @@ System\Ps2\SPU2 + + System\Ps2\SPU2 +