aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRainer Hochecker <fernetmenta@online.de>2018-08-24 20:41:17 +0200
committerRainer Hochecker <fernetmenta@online.de>2018-08-25 08:25:58 +0200
commit37b5badde0cef511e8daccf73c328ad72f10a1d6 (patch)
treee8db78d73df82f96ec3199d7ddcedf373d32596a
parent6854871e72d59733f2d935a2cd93aa6a47e2a294 (diff)
disable: Prefer stereo streams if user has configured 2.0 in AE
-rw-r--r--xbmc/Application.cpp4
-rw-r--r--xbmc/settings/AdvancedSettings.cpp2
-rw-r--r--xbmc/settings/AdvancedSettings.h1
3 files changed, 6 insertions, 1 deletions
diff --git a/xbmc/Application.cpp b/xbmc/Application.cpp
index df477d7325..f39a94e967 100644
--- a/xbmc/Application.cpp
+++ b/xbmc/Application.cpp
@@ -3177,7 +3177,9 @@ bool CApplication::PlayFile(CFileItem item, const std::string& player, bool bRes
else
options.fullscreen = g_advancedSettings.m_fullScreenOnMovieStart && !CMediaSettings::GetInstance().DoesVideoStartWindowed();
- options.preferStereo = CServiceBroker::GetActiveAE()->HasStereoAudioChannelCount();
+ // stereo streams may have lower quality, i.e. 32bit vs 16 bit
+ options.preferStereo = g_advancedSettings.m_videoPreferStereoStream &&
+ CServiceBroker::GetActiveAE()->HasStereoAudioChannelCount();
// reset VideoStartWindowed as it's a temp setting
CMediaSettings::GetInstance().SetVideoStartWindowed(false);
diff --git a/xbmc/settings/AdvancedSettings.cpp b/xbmc/settings/AdvancedSettings.cpp
index eded852e86..e7f6cd3748 100644
--- a/xbmc/settings/AdvancedSettings.cpp
+++ b/xbmc/settings/AdvancedSettings.cpp
@@ -146,6 +146,7 @@ void CAdvancedSettings::Initialize()
m_DXVAAllowHqScaling = true;
m_videoFpsDetect = 1;
m_maxTempo = 1.55f;
+ m_videoPreferStereoStream = false;
m_mediacodecForceSoftwareRendering = false;
@@ -677,6 +678,7 @@ void CAdvancedSettings::ParseSettingsFile(const std::string &file)
//0 = disable fps detect, 1 = only detect on timestamps with uniform spacing, 2 detect on all timestamps
XMLUtils::GetInt(pElement, "fpsdetect", m_videoFpsDetect, 0, 2);
XMLUtils::GetFloat(pElement, "maxtempo", m_maxTempo, 1.5, 2.1);
+ XMLUtils::GetBoolean(pElement, "preferstereostream", m_videoPreferStereoStream);
// Store global display latency settings
TiXmlElement* pVideoLatency = pElement->FirstChildElement("latency");
diff --git a/xbmc/settings/AdvancedSettings.h b/xbmc/settings/AdvancedSettings.h
index 0b0b027ac7..be771cb3bb 100644
--- a/xbmc/settings/AdvancedSettings.h
+++ b/xbmc/settings/AdvancedSettings.h
@@ -180,6 +180,7 @@ class CAdvancedSettings : public ISettingCallback, public ISettingsHandler
int m_videoFpsDetect;
bool m_mediacodecForceSoftwareRendering;
float m_maxTempo;
+ bool m_videoPreferStereoStream = false;
std::string m_videoDefaultPlayer;
float m_videoPlayCountMinimumPercent;