[mythtv-users] User Job to rip subtitles from each program

Raymond Wagner raymond at wagnerrp.com
Thu Jan 19 17:46:00 UTC 2012


On 1/19/2012 09:19, David Crawford wrote:
> Thanks, I'll check that out, are there any instructions to set that up?

Note that this utility was not added until 0.25.  See commit...

https://github.com/MythTV/mythtv/commit/48079bbda6e274754e3db72df8aca159d02aeb8e

In a quick test run...

 > mythccextractor --infile 
/srv/mounts/twotb_1/recordings/4481_20120118210000.mpg
 > ls /srv/mounts/twotb_1/recordings/4481_20120118210000.*
/srv/mounts/twotb_1/recordings/4481_20120118210000.608-cc1.und.srt
/srv/mounts/twotb_1/recordings/4481_20120118210000.708-service-01.und.srt

Looking back at your original question, you would need to use 
'%DIR%/%FILE%', as file is only the basename of the recording.  You may 
also have permissions issues writing to '~dave', since it would be run 
by whatever user was running the backend.  I threw together a quick 
wrapper script that would be used as "mythccextract_wrapper.py %JOBID% 
%VERBOSEMODE%", with optional --outdir and --rename.

> Only thing is - the scirpt i use exports the srt files to a certain 
> folder and in  a certain way where duplicate words from live news 
> subtitles are removed. I need this as I have a app that i use to make 
> keyword searches within in the subs. Is it possible to cut that 
> feature from that script and place in mythccextractor?

Mythccextract writes the srt files as another player would expect them 
to appear for proper playback.  I expect whatever duplicate filtering 
you are doing is too application specific to have much use out of your 
own.  You would have to wrap that around the output files, but using 
mythccextract would mean you weren't having to maintain your own 
mechanism for extraction captions from the video.  You may want to 
consider dumping the captions into a database, and doing such filtering 
at runtime instead.  I know SageTV operates that way, and I expect 
Digital Nirvana (who submitted the mythccextract patches) configures 
their systems in that manner as well.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mythccextract_wrapper.py
Url: http://www.mythtv.org/pipermail/mythtv-users/attachments/20120119/805001b9/attachment.pl 


More information about the mythtv-users mailing list