Per-channel merging of consecutive recordings

What would you like to see in MythTV and why? Find others who might want to help implement your ideas!
Forum rules
Please be reasonable and positive with your feature requests, remember that all contributions to MythTV are by volunteers in their spare time. MythTV won't support piracy in any form, including torrents and use of soft cams, so to avoid embarrassment please do not ask.

* One suggestion per thread please. Do not post new suggestions in replies. *
Post Reply
Posts: 1
Joined: Mon Sep 17, 2018 3:33 pm
Great Britain

Per-channel merging of consecutive recordings

Post by XavUK » Mon Sep 17, 2018 3:56 pm

Some channels annoyingly split movies into two parts, often with a brief news update in the middle. Currently I have to manually ensure that all three programmes are recorded, then play them back in the right order. I would love to have a way to flag that a channel engages in such behaviour, and that the scheduler should automatically extend a recording to encompass the next one or two listed programmes.

This could be implemented with the usual duplicates policy - presuming that the second part of the film has the same details as the first. When a recording is scheduled to take place on one of the flagged channels, MythTV would check the next two programmes, and if either is the "same" as the programme being scheduled the recording end time would be adjusted accordingly. "Two" might need to be "n" - e.g. if both the news and weather are listed as separate interstitial programmes - but in the interest of simplicity I think two would cover most current cases, and allow for the UI to be a checkbox rather than a numeric input.

There is a potential problem if the scheduler tries to record the second part of a programme (because the tuners were busy for the first part), so it may also be necessary to "look back" to see if the previous programme or two was also a match. Presumably, in that case, the recording should not take place.

If anyone has alternative ideas about how to deal with this problem, I'd love to hear them. I'm getting fed up with settling down to watch a film, only to find that the recording is just 1hr long.

Posts: 311
Joined: Sun May 11, 2014 6:23 pm
Great Britain

Re: Per-channel merging of consecutive recordings

Post by PhilB » Tue Jul 19, 2022 9:32 pm

See 'automatically handle split films' in the UK section of the forum


User avatar
Posts: 766
Joined: Thu Feb 06, 2014 6:09 pm
Great Britain

Re: Per-channel merging of consecutive recordings

Post by paulh » Wed Jul 20, 2022 10:29 am

One interesting possibility I stumbled across is having the option in the XMLTV grabber to automatically merge programs that are split like this to be one program.

There is a fork of Gary's tv_grab_zz_sdjson_sqlite that has an --merge-split=n option
--merge-split=n Movies that are split in to two segments by news programmes will be automatically merged if the news is <=n minutes long. An example is "--merge-split=5" to remove programmes that are only five minutes long if they programmes either side have the same title.
which sounds exactly like what you are asking for.

The downside is it appears to not be kept in sync with Gary's version, currently 55 commits behind, and is obviously not supported by XMLTV at all so if something breaks you are on your own.

Post Reply