[mythtv] Wondering about changing the MythTV player Play/Pause behaviour...

Michael T. Dean mtdean at thirdcontact.com
Mon Dec 7 19:48:31 UTC 2015


On 12/07/2015 02:18 PM, John P Poet wrote:
> On Mon, Dec 7, 2015 at 11:35 AM Vaughan Harper wrote:
>
>> Folks,
>> In the UK, one of the major PVRs is Sky+ (comparable with Tivo in North
>> America?). The play/pause behaviour is different from the MythTV player
>> (with Sky+ if you are fast forwarding/scanning and you press Play then
>> it goes into Play x1 rather than pausing), so I'd like to change the
>> MythTV behaviour to match Sky+, in order to make it easier switching
>> from one to another. (I'd also like to change the speed up/slow down
>> behaviour to match Sky+ and try and emulate the Apple TV "what was that"
>> feature to replay the last 30 seconds with subtitles on.)
>>
>> So I'm wondering whether there would be there would be general interest
>> in this or whether I should just do it as a personal fork. It seems like
>> the key changes would be in tv_play.cpp, but I guess that if it were to
>> be adopted there would have to be a setting to control whether to stick
>> with the existing behaviour or use this changed behaviour, so that would
>> require more changes to set/store this setting.
>>
>> What do people think? Shall I just do my own thing, or should I submit
>> the work?
> In Myth, the 'P' is mapped to PAUSE by default.  The PAUSE action toggles
> between Play and Pause.  The is also a PLAY action (I have it mapped to
> Ctrl+P), which always goes into the Play mode.  If you are talking about
> FFWD/RWND, then hitting Ctrl+P may solve that problem for you.
>
... (and lots more good info from job) ...
> In summary, you may be able to get most of the way to your goal without any
> code changes, but with some configuration.
>

And as far as the new behaviors (like the "what was that" you 
mentioned), if you do code to provide the feature, it should be done as 
a separate action, rather than changing the TV Playback/SEEKRWND 
action.  You could make a TV Playback/REPLAYWITHSUBS.  Note, too, that 
you'll have to deal with "everything else" if you try to implement 
that--where "everything else" includes things like a) choosing the right 
subtitle or caption stream (something that's easy if you're making a DVR 
for Sky only, but hard when trying to work with TV all around the 
world), b) handling cases where subtitles/captions are already enabled 
(without changing the chosen subtitle/caption stream), c) handle cases 
where the button is pressed multiple times (without blindly toggling 
captions for each press), and d) if the subtitles are supposed to go 
back off after, you'll need to handle the case where subtitles were on 
before (and leave them on after), among other things.

Note, too, that with LIRC, you can actually map multiple configs to a 
single button, such that they are passed to the application in turn (see 
http://www.lirc.org/html/configure.html#lircrc_format ). So, you could 
actually change your ~/.lircrc such that you have something like:

	begin
	    prog   = mythtv
	    button = KEY_REWIND
	    config = Left
	    config = T
	end


(where I'm assuming that Left is mapped to TV Playback/SEEKRWND and T is 
mapped to TV Playback/TOGGLECC or TV Playback/TOGGLESUBTITLE or whatever 
is appropriate in your case).  You may also find it works more 
smoothly/is better at picking up the subs if you send T first, then 
Left.  This would give you something like (or exactly like?) your "what 
was that feature".

Of course, if you're using a the Linux kernel "remote controls are 
nothing more than stupid keyboards" driver for your remote, you can't do 
this.

Mike


More information about the mythtv-dev mailing list