[mythtv-users] Disable MythVideo filename parsing

Paul Harrison mythtv at mythqml.net
Wed Sep 1 15:37:36 UTC 2021

On 31/08/2021 20:55, revans wrote:

> On Tue, 31 Aug 2021 17:31:00 +0100
> David Watkins <watkinshome at gmail.com> wrote:
>>> I do have a frontend only in addition to a frontend/backend but I
>>> have verified all metadata lookup is turned off on both machines.
>>> Also as I mentioned in a later post, I found what looks like code in
>>> videometadata.cpp which is intended to extract information from the
>>> filename and insert it into the database.
>> I spent quite a long time renaming some of my old orphaned recordings
>> to try to get that code to create metadata.  I never really got it to
>> do what I wanted.
> I can say with certainty it is parsing the filename and using the
> information to guess title, subtitle, season, and episode. This is with
> all settings for metadata turned off.
> It is also not consistent with the data, one directory I have has files
> named like 01-name.mp4, 02-name.mp4 etc. This works fine until we get to
> one named 10-name.mp4. Starting at that file it starts trying to guess
> subtitle, episode etc.
> Removing that particular file, doing a rescan then putting it back in
> causes the exact same behavior.

An alternative to relying on the filename parsing is to use an mxml file 
to supply the metadata you want which is what I often do.

You just need to name the mxml with the same name as the video file but 
with .mxml for the extension.

When you rescan for video's or ask for one video to update it's metadata 
and if there is an .mxml or .nfo file available then the metadata from 
there will be used.

An example .mxml file is below (See the wiki page for more details here 
:- https://www.mythtv.org/wiki/MythTV_Universal_Metadata_Format )

<!DOCTYPE MythMetadataXML>
         <title>Full Steam Ahead</title>
         <description>2/6. Series exploring the expansion of railways in 
the Victorian era. This episode looks at how railways began to move 
people, rather than just goods, around the country. [HD] [AD,S] Recorded 
from BBC Two HD on Monday 19 December 2016 at 04:00 pm.</description>
         <chansign>BBC Two HD</chansign>
         <startts>Mon, 19 December 2016 16:00:00</startts>
             <category type="genre" name="Railways"/>

In your case it sounds like you would want to change the title to 
something like '10-name.mp4' and probably remove or leave blank most of 
the other elements - I've got to say you are officially weird if that is 
what you really want :).

Paul H.

More information about the mythtv-users mailing list