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
+2 -2
View File
@@ -194,8 +194,8 @@ StreamCommandLineParser::StreamCommandLineParser()
{"borderless", StreamingPreferences::WM_FULLSCREEN_DESKTOP}, {"borderless", StreamingPreferences::WM_FULLSCREEN_DESKTOP},
}; };
m_AudioConfigMap = { m_AudioConfigMap = {
{"stereo", StreamingPreferences::AC_FORCE_STEREO}, {"stereo", StreamingPreferences::AC_STEREO},
{"surround", StreamingPreferences::AC_FORCE_SURROUND}, {"5.1-surround", StreamingPreferences::AC_51_SURROUND},
}; };
m_VideoCodecMap = { m_VideoCodecMap = {
{"auto", StreamingPreferences::VCC_AUTO}, {"auto", StreamingPreferences::VCC_AUTO},
+2 -2
View File
@@ -408,11 +408,11 @@ ScrollView {
id: audioListModel id: audioListModel
ListElement { ListElement {
text: "Stereo" text: "Stereo"
val: StreamingPreferences.AC_FORCE_STEREO val: StreamingPreferences.AC_STEREO
} }
ListElement { ListElement {
text: "5.1 surround sound" 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 // ::onActivated must be used, as it only listens for when the index is changed by a human
+1 -1
View File
@@ -44,7 +44,7 @@ void StreamingPreferences::reload()
enableMdns = settings.value(SER_MDNS, true).toBool(); enableMdns = settings.value(SER_MDNS, true).toBool();
mouseAcceleration = settings.value(SER_MOUSEACCELERATION, false).toBool(); mouseAcceleration = settings.value(SER_MOUSEACCELERATION, false).toBool();
audioConfig = static_cast<AudioConfig>(settings.value(SER_AUDIOCFG, 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, videoCodecConfig = static_cast<VideoCodecConfig>(settings.value(SER_VIDEOCFG,
static_cast<int>(VideoCodecConfig::VCC_AUTO)).toInt()); static_cast<int>(VideoCodecConfig::VCC_AUTO)).toInt());
videoDecoderSelection = static_cast<VideoDecoderSelection>(settings.value(SER_VIDEODEC, videoDecoderSelection = static_cast<VideoDecoderSelection>(settings.value(SER_VIDEODEC,
+2 -3
View File
@@ -33,9 +33,8 @@ public:
enum AudioConfig enum AudioConfig
{ {
AC_AUTO, AC_STEREO,
AC_FORCE_STEREO, AC_51_SURROUND
AC_FORCE_SURROUND
}; };
Q_ENUM(AudioConfig) Q_ENUM(AudioConfig)
+2 -2
View File
@@ -328,10 +328,10 @@ void Session::initialize()
switch (m_Preferences->audioConfig) switch (m_Preferences->audioConfig)
{ {
case StreamingPreferences::AC_FORCE_STEREO: case StreamingPreferences::AC_STEREO:
m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_STEREO; m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_STEREO;
break; break;
case StreamingPreferences::AC_FORCE_SURROUND: case StreamingPreferences::AC_51_SURROUND:
m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_51_SURROUND; m_StreamConfig.audioConfiguration = AUDIO_CONFIGURATION_51_SURROUND;
break; break;
} }