diff options
author | Arne Morten Kvarving <cptspiff@gmail.com> | 2015-01-28 15:36:44 +0100 |
---|---|---|
committer | uNiversaI <uNiversal@noreply.github.com> | 2015-07-03 22:30:00 +0900 |
commit | 908112ce2b16b1b2f856a6f6b4b9db4d8fbd5d55 (patch) | |
tree | 99f29478429fcb176d772275245f84ead044381f | |
parent | e836b9faf7ff5c42476bdce9e77fdaf41de33f9a (diff) |
WIP: nonlinear stretch 16:9 setting for 4:3 video display
-rw-r--r-- | addons/resource.language.en_gb/resources/strings.po | 5 | ||||
-rw-r--r-- | system/settings/settings.xml | 1 | ||||
-rw-r--r-- | xbmc/cores/VideoRenderers/BaseRenderer.cpp | 6 | ||||
-rw-r--r-- | xbmc/settings/VideoSettings.h | 3 |
4 files changed, 13 insertions, 2 deletions
diff --git a/addons/resource.language.en_gb/resources/strings.po b/addons/resource.language.en_gb/resources/strings.po index ff32bfd77e..3a73ad8896 100644 --- a/addons/resource.language.en_gb/resources/strings.po +++ b/addons/resource.language.en_gb/resources/strings.po @@ -2779,6 +2779,11 @@ msgctxt "#643" msgid "Avoid clipping on ReplayGained files" msgstr "" +#: system/settings/settings.xml +msgctxt "#644" +msgid "Stretch 16:9 - Nonlinear" +msgstr "" + #empty string with id 644 msgctxt "#645" diff --git a/system/settings/settings.xml b/system/settings/settings.xml index 8f69bcbef0..17c8a27914 100644 --- a/system/settings/settings.xml +++ b/system/settings/settings.xml @@ -587,6 +587,7 @@ <option label="630">0</option> <!-- ViewModeNormal --> <option label="633">3</option> <!-- ViewModeWideZoom --> <option label="634">4</option> <!-- ViewModeStretch16x9 --> + <option label="644">7</option> <!-- ViewModeStretch16x9 - nonlinear --> <option label="631">1</option> <!-- ViewModeZoom --> </options> </constraints> diff --git a/xbmc/cores/VideoRenderers/BaseRenderer.cpp b/xbmc/cores/VideoRenderers/BaseRenderer.cpp index bfafab743e..6979fa381e 100644 --- a/xbmc/cores/VideoRenderers/BaseRenderer.cpp +++ b/xbmc/cores/VideoRenderers/BaseRenderer.cpp @@ -688,7 +688,8 @@ void CBaseRenderer::SetViewMode(int viewMode) CDisplaySettings::Get().SetNonLinearStretched(true); } else if ( CMediaSettings::Get().GetCurrentVideoSettings().m_ViewMode == ViewModeStretch16x9 || - (is43 && CSettings::Get().GetInt("videoplayer.stretch43") == ViewModeStretch16x9)) + (is43 && (CSettings::Get().GetInt("videoplayer.stretch43") == ViewModeStretch16x9 || + CSettings::Get().GetInt("videoplayer.stretch43") == ViewModeStretch16x9Nonlin))) { // stretch image to 16:9 ratio CDisplaySettings::Get().SetZoomAmount(1.0); if (res == RES_PAL_4x3 || res == RES_PAL60_4x3 || res == RES_NTSC_4x3 || res == RES_HDTV_480p_4x3) @@ -701,6 +702,9 @@ void CBaseRenderer::SetViewMode(int viewMode) // incorrect behaviour, but it's what the users want, so... CDisplaySettings::Get().SetPixelRatio((screenWidth / screenHeight) * info.fPixelRatio / sourceFrameRatio); } + if (is43) + CDisplaySettings::Get().SetNonLinearStretched(CSettings::Get().GetInt("videoplayer.stretch43") == ViewModeStretch16x9Nonlin); + } else if (CMediaSettings::Get().GetCurrentVideoSettings().m_ViewMode == ViewModeOriginal) { // zoom image so that the height is the original size diff --git a/xbmc/settings/VideoSettings.h b/xbmc/settings/VideoSettings.h index 66c3504de8..03050586b0 100644 --- a/xbmc/settings/VideoSettings.h +++ b/xbmc/settings/VideoSettings.h @@ -111,7 +111,8 @@ typedef enum { ViewModeWideZoom, ViewModeStretch16x9, ViewModeOriginal, - ViewModeCustom + ViewModeCustom, + ViewModeStretch16x9Nonlin } ViewMode; class CVideoSettings |