pyTivo Discussion Forum Forum Index pyTivo Discussion Forum
Answers and the development of pyTivo a TiVo transcoding server
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Dynamic metadata

 
Post new topic   Reply to topic    pyTivo Discussion Forum Forum Index -> pyTivo
 View previous topic :: View next topic  
Author Message
JonMikelV



Joined: 22 Feb 2008
Posts: 40

PostPosted: Thu May 15, 2008 6:56 am    Post subject: Dynamic metadata Reply with quote

Sorry for the multiple posts, but I wanted each idea in it's own topic.

I've got a lot of series TV hosted by my pyTiVo. It's all laid out in a nice directory format broken up by series, season, etc. with file names indicating the season's episode #.
Series A\Season 01\01-Episode1
Series A\Season 02\01-Episode1
Series B\Season 01\01-Episode1
etc.

This works great for a file structure but in the NPL I end up with series and season episodes all jumbled together:
01-Episode1
01-Episode1
01-Episode1

I realize I could use a metafile for each video file to fix this issue - but that's a LOT of metafiles to be created. And I'm lazy.

So I fiddled a bit around line 285 of the pluigins\video\video.py file with the following:

Code:
                if key.startswith('seriesT'):
#                    regEx = re.compile( '%n')
#                    value = regEx.sub( fileName, view)
                    value = value.replace('%n', 'fname')
                    value = value.replace('%x', 'ext')
                    value = value.replace('%p', 'parent')


This opens up all sorts of possibilities of abusing, um, I mean enhancing default.txt metadata files.

For example - tweaking 3 default.txt files like this:
seriesTitle : Series A 01.%n (where %n is file name)
seriesTitle : Series A 02.%n
seriesTitle : Series B 01.%n

Could show up in the NPL as:
Series A 01.01-Episode1
Series A 02.01-Episode1
Series B 01.01-Episode1

Or even better (assuming I could get it working) a more generic:
seriesTitle : %p.%n (where %p is parent folder name and %n is file name).

With a little more thought we could probably make it very generic and just allow regular expressions. This would enable things like being able to remove file extensions and the like.

By applying it to more than just seriesTitle we could do things like auto-populate episode # (assuming a file naming convention that begins with "ep-" for example) or include actual/original file name in the Info section so an NPL entry could have an abbreviated series name to better fit the screen, but we could still get the full series name on the info screen.

Does this sound like a useful feature to anybody else?

Thanks.

Jon-Mikel
Back to top
View user's profile Send private message
wmcbrine



Joined: 04 Jan 2008
Posts: 444

PostPosted: Thu May 15, 2008 8:34 am    Post subject: Reply with quote

Interesting.
_________________
My pyTivo fork
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    pyTivo Discussion Forum Forum Index -> pyTivo All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
Site is in NO WAY affiliated with TiVo Inc

Powered by phpBB © 2001, 2005 phpBB Group
phpBB SEO
[ Time: 0.4665s ][ Queries: 13 (0.3777s) ][ Debug on ]