Well, I finally took the time to look into the real problem a bit more and
after redefining my problem I came up with a solution. I have now tested this
solution and it works very well.
This is it:
During playback of recordings, you cannot change channels anyway so I decided
to utilize the fact that we had an input mechanism already in place here.
What I basically did was say: 'If someone enters a number, followed by
'T' (or whatever TOGGLECC is set to), set this page as the default page and
turn teletext on. Voil� the page in question is selected and immediately
'tuned', you can tune to a new page on the fly. I have tried various common
pages here in Denmark: DR1 (399), TV2 (333) and SVT1 (199) - All of these
works like a charm. You turn text off again by simply pressing 'T'.
I have tried to enter invalid page numbers and if has no bad effect (just no
text). The maximum entry of 9999 does not cause problems.
Attached is the (in the end quite simple) patch.
I hope this is decent enough for inclusion. It suits my needs at least.
/Martin.
Index: keys.txt
===================================================================
RCS file: /var/lib/mythcvs/mythtv/keys.txt,v
retrieving revision 1.75
diff -u -r1.75 keys.txt
--- keys.txt 10 Feb 2005 19:01:07 -0000 1.75
+++ keys.txt 14 Feb 2005 23:58:07 -0000
@@ -39,6 +39,7 @@
- End or 'Z' to skip to next commercial break marker
- Home or 'Q' to skip back to previous commercial break marker
- T to toggle close caption support
+- Pressing 0 - 9 (preferrably 3 times) + T changes teletext page and turns on teletext pages
- F to rotate between the various Picture Adjustments (Colour, Hue, etc.)
While Picture Adjustment is on-screen, use Left and Right arrows to adjust.
These settings adjust the look of the video playback, and are independent
Index: libs/libmythtv/NuppelVideoPlayer.cpp
===================================================================
RCS file: /var/lib/mythcvs/mythtv/libs/libmythtv/NuppelVideoPlayer.cpp,v
retrieving revision 1.436
diff -u -r1.436 NuppelVideoPlayer.cpp
--- libs/libmythtv/NuppelVideoPlayer.cpp 11 Feb 2005 04:21:24 -0000 1.436
+++ libs/libmythtv/NuppelVideoPlayer.cpp 14 Feb 2005 23:58:12 -0000
@@ -926,10 +926,9 @@
cc = true;
if (mode == 1)
{
- // TODO: teletext page select
- //if (arg)
- // vbipagenr = (arg & 0xffff) << 16;
- //msg = QString("%1%2").arg(QObject::tr("TXT pg")).arg(vbipagenr);
+ // Teletext page select (set in DoToggleCC in tv_play.cpp)
+ if (arg)
+ vbipagenr = arg;
msg = QObject::tr("TXT on");
}
else if (mode == 2)
Index: libs/libmythtv/tv_play.cpp
===================================================================
RCS file: /var/lib/mythcvs/mythtv/libs/libmythtv/tv_play.cpp,v
retrieving revision 1.240
diff -u -r1.240 tv_play.cpp
--- libs/libmythtv/tv_play.cpp 9 Feb 2005 20:27:48 -0000 1.240
+++ libs/libmythtv/tv_play.cpp 14 Feb 2005 23:58:15 -0000
@@ -1577,8 +1577,12 @@
action = actions[i];
handled = true;
- if (action == "TOGGLECC")
- DoToggleCC(0);
+ if (action == "TOGGLECC") {
+ bool valid = false;
+ int Page = QueuedChannel().toInt(&valid, 16) << 16;
+ ChannelClear();
+ DoToggleCC(Page);
+ }
else if (action == "SKIPCOMMERCIAL")
DoSkipCommercials(1);
else if (action == "SKIPCOMMBACK")
_______________________________________________
mythtv-dev mailing list
[email protected]
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev