Index: libs/libmythtv/NuppelVideoPlayer.h =================================================================== --- libs/libmythtv/NuppelVideoPlayer.h (revision 9372) +++ libs/libmythtv/NuppelVideoPlayer.h (working copy) @@ -145,9 +145,10 @@ void SetForcedAspectRatio(int mpeg2_aspect_value, int letterbox_permission); void NextScanType(void) - { SetScanType((FrameScanType)(((int)m_scan + 1) & 0x3)); } + { SetScanType((FrameScanType)(((int)GetScanType() + 1) & 0x3)); } void SetScanType(FrameScanType); - FrameScanType GetScanType(void) const { return m_scan; } + FrameScanType GetCurrentScanType(void) const { return m_scan; } + FrameScanType GetScanType(void) const { return m_scan_locked ? m_scan : kScan_Detect; } void SetOSDFontName(const QString osdfonts[22], const QString &prefix); void SetOSDThemeName(const QString themename); Index: libs/libmythtv/tv_play.cpp =================================================================== --- libs/libmythtv/tv_play.cpp (revision 9372) +++ libs/libmythtv/tv_play.cpp (working copy) @@ -1825,6 +1825,16 @@ return false; } +static inline QString toQString(FrameScanType scan) { + switch (scan) { + case kScan_Detect: return QObject::tr("Detect"); + case kScan_Interlaced: return QObject::tr("Interlaced (Normal)"); + case kScan_Intr2ndField: return QObject::tr("Interlaced (Reversed)"); + case kScan_Progressive: return QObject::tr("Progressive"); + default: return QObject::tr("Unknown"); + } +} + void TV::ProcessKeypress(QKeyEvent *e) { #if DEBUG_ACTIONS @@ -2246,9 +2256,11 @@ DoTogglePictureAttribute(); } } - else if (action == "NEXTSCAN") + else if (action == "NEXTSCAN") { activenvp->NextScanType(); - else if (action == "ARBSEEK") + if (GetOSD()) + GetOSD()->SetSettingsText(toQString(activenvp->GetScanType()), 3); + } else if (action == "ARBSEEK") { if (asInputMode) { @@ -3197,6 +3209,14 @@ mesg += " %1X"; mesg = mesg.arg(normal_speed); } + FrameScanType scan_type = activenvp->GetCurrentScanType(); + switch (scan_type) { + case kScan_Progressive: + mesg += " (Progressive)"; break; + case kScan_Interlaced: + case kScan_Intr2ndField: + mesg += " (Interlaced)"; break; + } return mesg; } @@ -6053,7 +6073,7 @@ "STRETCHGROUP"); // add scan mode override settings to menu - int scan_type = kScan_Ignore; + FrameScanType scan_type = kScan_Ignore; if (activenvp) scan_type = activenvp->GetScanType(); @@ -6061,16 +6081,16 @@ treeMenu, tr("Video Scan"), "SCANMODE"); subitem = new OSDGenericTree( item, tr("Detect"), "SELECTSCAN_3", - (scan_type == 3) ? 1 : 0, NULL, "SCANGROUP"); + (scan_type == kScan_Detect) ? 1 : 0, NULL, "SCANGROUP"); subitem = new OSDGenericTree( item, tr("Progressive"), "SELECTSCAN_0", - (scan_type == 0) ? 1 : 0, NULL, "SCANGROUP"); + (scan_type == kScan_Progressive) ? 1 : 0, NULL, "SCANGROUP"); subitem = new OSDGenericTree( item, tr("Interlaced (Normal)"), "SELECTSCAN_1", - (scan_type == 1) ? 1 : 0, NULL, "SCANGROUP"); + (scan_type == kScan_Interlaced) ? 1 : 0, NULL, "SCANGROUP"); subitem = new OSDGenericTree( item, tr("Interlaced (Reversed)"), "SELECTSCAN_2", - (scan_type == 2) ? 1 : 0, NULL, "SCANGROUP"); + (scan_type == kScan_Intr2ndField) ? 1 : 0, NULL, "SCANGROUP"); // add sleep items to menu