mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-31 21:28:51 +00:00
Move DSP settings to dolphin.ini
This commit is contained in:
parent
3cb4300439
commit
196c2867ad
15 changed files with 71 additions and 158 deletions
|
@ -256,6 +256,12 @@ void SConfig::SaveSettings()
|
|||
ini.Set("Movie", "PauseMovie", m_PauseMovie);
|
||||
ini.Set("Movie", "Author", m_strMovieAuthor);
|
||||
|
||||
// DSP
|
||||
ini.Set("DSP", "EnableJIT", m_EnableJIT);
|
||||
ini.Set("DSP", "DumpAudio", m_DumpAudio);
|
||||
ini.Set("DSP", "Backend", sBackend);
|
||||
ini.Set("DSP", "Volume", m_Volume);
|
||||
|
||||
ini.Save(File::GetUserPath(F_DOLPHINCONFIG_IDX));
|
||||
m_SYSCONF->Save();
|
||||
}
|
||||
|
@ -404,6 +410,20 @@ void SConfig::LoadSettings()
|
|||
// Movie
|
||||
ini.Get("General", "PauseMovie", &m_PauseMovie, false);
|
||||
ini.Get("Movie", "Author", &m_strMovieAuthor, "");
|
||||
|
||||
// DSP
|
||||
ini.Get("Config", "EnableJIT", &m_EnableJIT, true);
|
||||
ini.Get("Config", "DumpAudio", &m_DumpAudio, false);
|
||||
#if defined __linux__ && HAVE_ALSA
|
||||
ini.Get("Config", "Backend", &sBackend, BACKEND_ALSA);
|
||||
#elif defined __APPLE__
|
||||
ini.Get("Config", "Backend", &sBackend, BACKEND_COREAUDIO);
|
||||
#elif defined _WIN32
|
||||
ini.Get("Config", "Backend", &sBackend, BACKEND_DIRECTSOUND);
|
||||
#else
|
||||
ini.Get("Config", "Backend", &sBackend, BACKEND_NULLSOUND);
|
||||
#endif
|
||||
ini.Get("Config", "Volume", &m_Volume, 100);
|
||||
}
|
||||
|
||||
m_SYSCONF = new SysConf();
|
||||
|
|
|
@ -26,6 +26,16 @@
|
|||
#include "HW/SI_Device.h"
|
||||
#include "SysConf.h"
|
||||
|
||||
// DSP Backend Types
|
||||
#define BACKEND_NULLSOUND "No audio output"
|
||||
#define BACKEND_ALSA "ALSA"
|
||||
#define BACKEND_AOSOUND "AOSound"
|
||||
#define BACKEND_COREAUDIO "CoreAudio"
|
||||
#define BACKEND_DIRECTSOUND "DSound"
|
||||
#define BACKEND_OPENAL "OpenAL"
|
||||
#define BACKEND_PULSEAUDIO "Pulse"
|
||||
#define BACKEND_XAUDIO2 "XAudio2"
|
||||
|
||||
struct SConfig : NonCopyable
|
||||
{
|
||||
// Wii Devices
|
||||
|
@ -83,6 +93,12 @@ struct SConfig : NonCopyable
|
|||
bool m_ShowLag;
|
||||
std::string m_strMovieAuthor;
|
||||
|
||||
// DSP settings
|
||||
bool m_EnableJIT;
|
||||
bool m_DumpAudio;
|
||||
int m_Volume;
|
||||
std::string sBackend;
|
||||
|
||||
SysConf* m_SYSCONF;
|
||||
|
||||
// save settings
|
||||
|
|
|
@ -22,8 +22,6 @@
|
|||
|
||||
DSPEmulator *CreateDSPEmulator(bool HLE)
|
||||
{
|
||||
ac_Config.Load();
|
||||
|
||||
if (HLE)
|
||||
{
|
||||
return new DSPHLE();
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include "DSPHLE.h"
|
||||
#include "UCodes/UCodes.h"
|
||||
#include "../AudioInterface.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
DSPHLE::DSPHLE() {
|
||||
m_InitMixer = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue