Revert "- allow to force given osd resolution in "videosystem = auto" mode"

This reverts commit 6fc24e990b.
This commit is contained in:
M. Liebmann
2017-03-12 06:32:52 +01:00
parent 87cb1b514a
commit 5ce34d5cf9
9 changed files with 25 additions and 65 deletions

View File

@@ -325,10 +325,6 @@ colormenu.font_ttx Teletext Schriftart
colormenu.menucolors Farben
colormenu.osd_preset Monitor Auswahl
colormenu.osd_resolution OSD-Auflösung
colormenu.osd_resolution_force OSD-Auflösung erzwingen
colormenu.osd_resolution_force_all in allen Modi
colormenu.osd_resolution_force_hd in HD-Modi
colormenu.osd_resolution_force_never nie
colormenu.textcolor Textfarbe
colormenu.themeselect Theme auswählen
colormenu.timing Timeouts
@@ -1256,8 +1252,7 @@ menu.hint_opkg_upgrade Aktualisiert alle installierten Pakete auf die neueste ve
menu.hint_osd Farben, Schriftarten, Anzeigegröße, Ansichtsoptionen der Menüs usw.
menu.hint_osd_language Wählen Sie ihre Menü-Sprache
menu.hint_osd_preset Wählen Sie zwischen Röhren-TV (CRT) oder Flachbildschirm (LCD)
menu.hint_osd_resolution Wählen Sie eine OSD-Auflösung
menu.hint_osd_resolution_force Erzwingt die eingestellte OSD-Auflösung, auch wenn das Videosystem automatisch umgeschalten wird
menu.hint_osd_resolution Wählen Sie eine OSD Auflösung
menu.hint_osd_timing Einblendzeit, die das OSD auf dem TV angezeigt wird
menu.hint_other_fonts Ändern Sie andere Schriftgrößen
menu.hint_parentallock_changepin Geben Sie den 4-stelligen PIN-Code ein, der dann ggf. abgefragt wird

View File

@@ -325,10 +325,6 @@ colormenu.font_ttx Select Teletext font
colormenu.menucolors Colors
colormenu.osd_preset TV preset
colormenu.osd_resolution OSD resolution
colormenu.osd_resolution_force Force OSD resolution
colormenu.osd_resolution_force_all in all modes
colormenu.osd_resolution_force_hd in HD modes
colormenu.osd_resolution_force_never never
colormenu.textcolor Text color
colormenu.themeselect Select theme
colormenu.timing Timeouts
@@ -1257,7 +1253,6 @@ menu.hint_osd Colors, fonts, screen size\nGUI look and feel options
menu.hint_osd_language Select OSD language
menu.hint_osd_preset Pre-configured screen margins for CRT and LCD TV
menu.hint_osd_resolution Change OSD resolution
menu.hint_osd_resolution_force Forces the given OSD resolution, even when the videosystem is auto-changed
menu.hint_osd_timing After this time the OSD will be faded out
menu.hint_other_fonts Change other font sizes
menu.hint_parentallock_changepin Change PIN code

View File

@@ -61,9 +61,12 @@ void COsdHelpers::changeOsdResolution(uint32_t mode, bool automode/*=false*/, bo
if ((g_settings.video_Mode == VIDEO_STD_AUTO) &&
(g_settings.enabled_auto_modes[videoSystem] == 1) &&
(!allow_OSDMODE_1080(videoSystem)))
(!isVideoSystem1080(videoSystem)))
modeNew = OSDMODE_720;
// if (!isVideoSystem1080(videoSystem))
// modeNew = OSDMODE_720;
idx = frameBuffer->getIndexOsdResolution(modeNew);
resetOsd = (modeNew != getOsdResolution()) ? true : false;
#if 1
@@ -127,28 +130,28 @@ void COsdHelpers::changeOsdResolution(uint32_t, bool, bool)
}
#endif
bool COsdHelpers::allow_OSDMODE_1080(int res)
int COsdHelpers::isVideoSystem1080(int res)
{
if (g_settings.osd_resolution_force == FORCE_ALL || (
(res == VIDEO_STD_1080I50)
|| (res == VIDEO_STD_1080I60)
|| (res == VIDEO_STD_1080P24)
|| (res == VIDEO_STD_1080P25)
|| (res == VIDEO_STD_1080P30)
#ifdef BOXMODEL_CS_HD2
|| (res == VIDEO_STD_1080P50)
|| (res == VIDEO_STD_1080P60)
|| (res == VIDEO_STD_1080P2397)
|| (res == VIDEO_STD_1080P2997)
#endif
))
if ((res == VIDEO_STD_1080I60) ||
(res == VIDEO_STD_1080I50) ||
(res == VIDEO_STD_1080P30) ||
(res == VIDEO_STD_1080P24) ||
(res == VIDEO_STD_1080P25))
return true;
if (g_settings.osd_resolution_force == FORCE_HD && (
(res == VIDEO_STD_720P50)
|| (res == VIDEO_STD_720P60)
))
#ifdef BOXMODEL_CS_HD2
if ((res == VIDEO_STD_1080P50) ||
(res == VIDEO_STD_1080P60) ||
(res == VIDEO_STD_1080P2397) ||
(res == VIDEO_STD_1080P2997))
return true;
#endif
#if 0
/* for testing only */
if (res == VIDEO_STD_720P50)
return true;
#endif
return false;
}

View File

@@ -19,16 +19,10 @@ class COsdHelpers
int g_settings_osd_resolution_save;
void changeOsdResolution(uint32_t mode, bool automode=false, bool forceOsdReset=false);
bool allow_OSDMODE_1080(int res);
int isVideoSystem1080(int res);
int getVideoSystem();
uint32_t getOsdResolution();
int setVideoSystem(int newSystem, bool remember = true);
enum {
FORCE_NEVER = 0,
FORCE_HD,
FORCE_ALL
};
};

View File

@@ -397,14 +397,6 @@ const CMenuOptionChooser::keyval_ext OSD_PRESET_OPTIONS[] =
{ COsdSetup::PRESET_LCD, NONEXISTANT_LOCALE, "LCD" }
};
const CMenuOptionChooser::keyval OSD_RESOLUTION_FORCE_OPTIONS[]=
{
{ COsdHelpers::FORCE_NEVER, LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_NEVER },
{ COsdHelpers::FORCE_HD, LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_HD },
{ COsdHelpers::FORCE_ALL, LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_ALL }
};
int OSD_RESOLUTION_FORCE_OPTIONS_COUNT = sizeof(OSD_RESOLUTION_FORCE_OPTIONS)/sizeof(OSD_RESOLUTION_FORCE_OPTIONS[0]);
#define INFOBAR_CASYSTEM_MODE_OPTION_COUNT 4
const CMenuOptionChooser::keyval INFOBAR_CASYSTEM_MODE_OPTIONS[INFOBAR_CASYSTEM_MODE_OPTION_COUNT] =
{
@@ -670,17 +662,11 @@ int COsdSetup::showOsdSetup()
}
int videoSystem = COsdHelpers::getInstance()->getVideoSystem();
bool enable = ((resCount > 1) &&
COsdHelpers::getInstance()->allow_OSDMODE_1080(videoSystem) &&
COsdHelpers::getInstance()->isVideoSystem1080(videoSystem) &&
(g_settings.video_Mode != VIDEO_STD_AUTO));
CMenuOptionChooser * osd_res = new CMenuOptionChooser(LOCALE_COLORMENU_OSD_RESOLUTION, &g_settings.osd_resolution, kext, resCount, enable, this);
osd_res->setHint("", LOCALE_MENU_HINT_OSD_RESOLUTION);
osd_menu->addItem(osd_res);
// force resolution in auto-mode
enable = (g_settings.video_Mode == VIDEO_STD_AUTO);
CMenuOptionChooser * osd_res_force = new CMenuOptionChooser(LOCALE_COLORMENU_OSD_RESOLUTION_FORCE, &g_settings.osd_resolution_force, OSD_RESOLUTION_FORCE_OPTIONS, OSD_RESOLUTION_FORCE_OPTIONS_COUNT, enable, this);
osd_res_force->setHint("", LOCALE_MENU_HINT_OSD_RESOLUTION_FORCE);
osd_menu->addItem(osd_res_force);
#endif
//monitor

View File

@@ -726,7 +726,6 @@ int CNeutrinoApp::loadSetup(const char * fname)
//screen configuration
g_settings.osd_resolution = (osd_resolution_tmp == -1) ? configfile.getInt32("osd_resolution", 0) : osd_resolution_tmp;
COsdHelpers::getInstance()->g_settings_osd_resolution_save = g_settings.osd_resolution;
g_settings.osd_resolution_force = configfile.getInt32("osd_resolution_force", COsdHelpers::FORCE_NEVER);
g_settings.screen_StartX_crt_0 = configfile.getInt32("screen_StartX_crt_0", 80);
g_settings.screen_StartY_crt_0 = configfile.getInt32("screen_StartY_crt_0", 45);
g_settings.screen_EndX_crt_0 = configfile.getInt32("screen_EndX_crt_0" , 1280 - g_settings.screen_StartX_crt_0 - 1);
@@ -1368,7 +1367,6 @@ void CNeutrinoApp::saveSetup(const char * fname)
//screen configuration
configfile.setInt32("osd_resolution" , COsdHelpers::getInstance()->g_settings_osd_resolution_save);
configfile.setInt32("osd_resolution_force", g_settings.osd_resolution_force);
configfile.setInt32("screen_StartX_lcd_0", g_settings.screen_StartX_lcd_0);
configfile.setInt32("screen_StartY_lcd_0", g_settings.screen_StartY_lcd_0);
configfile.setInt32("screen_EndX_lcd_0" , g_settings.screen_EndX_lcd_0);

View File

@@ -352,10 +352,6 @@ typedef enum
LOCALE_COLORMENU_MENUCOLORS,
LOCALE_COLORMENU_OSD_PRESET,
LOCALE_COLORMENU_OSD_RESOLUTION,
LOCALE_COLORMENU_OSD_RESOLUTION_FORCE,
LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_ALL,
LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_HD,
LOCALE_COLORMENU_OSD_RESOLUTION_FORCE_NEVER,
LOCALE_COLORMENU_TEXTCOLOR,
LOCALE_COLORMENU_THEMESELECT,
LOCALE_COLORMENU_TIMING,
@@ -1284,7 +1280,6 @@ typedef enum
LOCALE_MENU_HINT_OSD_LANGUAGE,
LOCALE_MENU_HINT_OSD_PRESET,
LOCALE_MENU_HINT_OSD_RESOLUTION,
LOCALE_MENU_HINT_OSD_RESOLUTION_FORCE,
LOCALE_MENU_HINT_OSD_TIMING,
LOCALE_MENU_HINT_OTHER_FONTS,
LOCALE_MENU_HINT_PARENTALLOCK_CHANGEPIN,

View File

@@ -352,10 +352,6 @@ const char * locale_real_names[] =
"colormenu.menucolors",
"colormenu.osd_preset",
"colormenu.osd_resolution",
"colormenu.osd_resolution_force",
"colormenu.osd_resolution_force_all",
"colormenu.osd_resolution_force_hd",
"colormenu.osd_resolution_force_never",
"colormenu.textcolor",
"colormenu.themeselect",
"colormenu.timing",
@@ -1284,7 +1280,6 @@ const char * locale_real_names[] =
"menu.hint_osd_language",
"menu.hint_osd_preset",
"menu.hint_osd_resolution",
"menu.hint_osd_resolution_force",
"menu.hint_osd_timing",
"menu.hint_other_fonts",
"menu.hint_parentallock_changepin",

View File

@@ -626,7 +626,6 @@ struct SNeutrinoSettings
int screen_EndX_lcd_1;
int screen_EndY_lcd_1;
int osd_resolution;
int osd_resolution_force;
int screen_preset;
int screen_width;
int screen_height;