From 2e24996a9cbe60372ea643253f9dec7114baa697 Mon Sep 17 00:00:00 2001 From: OatmealDome Date: Sun, 3 Jan 2016 16:30:30 -0500 Subject: [PATCH 1/2] CoreAudioSound: Only include AudioUnit --- Source/Core/AudioCommon/CoreAudioSoundStream.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Core/AudioCommon/CoreAudioSoundStream.cpp b/Source/Core/AudioCommon/CoreAudioSoundStream.cpp index f6a26b442f..a85b26e2d5 100644 --- a/Source/Core/AudioCommon/CoreAudioSoundStream.cpp +++ b/Source/Core/AudioCommon/CoreAudioSoundStream.cpp @@ -2,7 +2,7 @@ // Licensed under GPLv2+ // Refer to the license.txt file included. -#include +#include #include "AudioCommon/CoreAudioSoundStream.h" #include "Common/Logging/Log.h" From 36a20c3535e799acfa72af4757aab8e7b3bb8e23 Mon Sep 17 00:00:00 2001 From: OatmealDome Date: Sun, 3 Jan 2016 16:33:02 -0500 Subject: [PATCH 2/2] CoreAudioSound: Replace deprecated parameters The kAudioUnitParameterFlag_* parameters don't exist on iOS. --- Source/Core/AudioCommon/CoreAudioSoundStream.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Core/AudioCommon/CoreAudioSoundStream.cpp b/Source/Core/AudioCommon/CoreAudioSoundStream.cpp index a85b26e2d5..38f11fb766 100644 --- a/Source/Core/AudioCommon/CoreAudioSoundStream.cpp +++ b/Source/Core/AudioCommon/CoreAudioSoundStream.cpp @@ -73,7 +73,7 @@ bool CoreAudioSound::Start() err = AudioUnitSetParameter(audioUnit, kHALOutputParam_Volume, - kAudioUnitParameterFlag_Output, 0, + kAudioUnitScope_Output, 0, m_volume / 100., 0); if (err != noErr) ERROR_LOG(AUDIO, "error setting volume"); @@ -102,7 +102,7 @@ void CoreAudioSound::SetVolume(int volume) err = AudioUnitSetParameter(audioUnit, kHALOutputParam_Volume, - kAudioUnitParameterFlag_Output, 0, + kAudioUnitScope_Output, 0, volume / 100., 0); if (err != noErr) ERROR_LOG(AUDIO, "error setting volume");