From 7415696492c588b6cce408e930f1fa88f389c373 Mon Sep 17 00:00:00 2001 From: ThorstenB Date: Mon, 17 Sep 2012 13:36:38 +0200 Subject: [PATCH] Create FGSoundManager as a wrapper for SGSoundMgr_OpenAl and sink all sound related code from main.cxx in there. --- src/ATCDCL/ATC.cxx | 2 + src/Main/fg_init.cxx | 4 +- src/Main/main.cxx | 78 +--------------------- src/Sound/CMakeLists.txt | 4 +- src/Sound/soundmanager.cxx | 131 +++++++++++++++++++++++++++++++++++++ src/Sound/soundmanager.hxx | 69 +++++++++++++++++++ 6 files changed, 208 insertions(+), 80 deletions(-) create mode 100644 src/Sound/soundmanager.cxx create mode 100644 src/Sound/soundmanager.hxx diff --git a/src/ATCDCL/ATC.cxx b/src/ATCDCL/ATC.cxx index 6aae329c9..982b151bc 100644 --- a/src/ATCDCL/ATC.cxx +++ b/src/ATCDCL/ATC.cxx @@ -188,6 +188,8 @@ void FGATC::Render(string& msg, const float volume, { NoRender(refname); } +#else + bool useVoice = false; #endif // ENABLE_AUDIO_SUPPORT if (!useVoice) diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index 651b0d443..82793ac2b 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -60,7 +60,6 @@ #include #include #include -#include #include #include @@ -98,6 +97,7 @@ #include #include #include +#include #include #include