Finish removal of auto audio option and rename the remaining options

This commit is contained in:
Cameron Gutman
2018-10-02 15:30:22 -07:00
parent 3dc049ee5f
commit bccd118abb
5 changed files with 9 additions and 10 deletions

View File

@@ -194,8 +194,8 @@ StreamCommandLineParser::StreamCommandLineParser()
{"borderless", StreamingPreferences::WM_FULLSCREEN_DESKTOP},
};
m_AudioConfigMap = {
{"stereo", StreamingPreferences::AC_FORCE_STEREO},
{"surround", StreamingPreferences::AC_FORCE_SURROUND},
{"stereo", StreamingPreferences::AC_STEREO},
{"5.1-surround", StreamingPreferences::AC_51_SURROUND},
};
m_VideoCodecMap = {
{"auto", StreamingPreferences::VCC_AUTO},

View File

@@ -408,11 +408,11 @@ ScrollView {
id: audioListModel
ListElement {
text: "Stereo"
val: StreamingPreferences.AC_FORCE_STEREO
val: StreamingPreferences.AC_STEREO
}
ListElement {
text: "5.1 surround sound"
val: StreamingPreferences.AC_FORCE_SURROUND
val: StreamingPreferences.AC_51_SURROUND
}
}
// ::onActivated must be used, as it only listens for when the index is changed by a human

View File

@@ -44,7 +44,7 @@ void StreamingPreferences::reload()
enableMdns = settings.value(SER_MDNS, true).toBool();
mouseAcceleration = settings.value(SER_MOUSEACCELERATION, false).toBool();
audioConfig = static_cast<AudioConfig>(settings.value(SER_AUDIOCFG,
static_cast<int>(AudioConfig::AC_AUTO)).toInt());
static_cast<int>(AudioConfig::AC_STEREO)).toInt());
videoCodecConfig = static_cast<VideoCodecConfig>(settings.value(SER_VIDEOCFG,
static_cast<int>(VideoCodecConfig::VCC_AUTO)).toInt());
videoDecoderSelection = static_cast<VideoDecoderSelection>(settings.value(SER_VIDEODEC,

View File

@@ -33,9 +33,8 @@ public:
enum AudioConfig
{
AC_AUTO,
AC_FORCE_STEREO,
AC_FORCE_SURROUND
AC_STEREO,
AC_51_SURROUND
};
Q_ENUM(AudioConfig)

View File

@@ -328,10 +328,10 @@ void Session::initialize()
switch (m_Preferences->audioConfig)
{
case StreamingPreferences::AC_FORCE_STEREO:
case StreamingPreferences::AC_STEREO:
m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_STEREO;
break;
case StreamingPreferences::AC_FORCE_SURROUND:
case StreamingPreferences::AC_51_SURROUND:
m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_51_SURROUND;
break;
}