[mythtv-users] export recordings w/commercials removed?
Matt Garman
matthew.garman at gmail.com
Mon Jul 18 02:14:04 UTC 2011
On Sun, Jul 17, 2011 at 01:00:31PM -0500, Matt Garman wrote:
> I'm currently running a combined FE+BE on an Arch Linux box:
>
> $ mythbackend --version
> Please attach all output as a file in bug reports.
> MythTV Version : 0.24
> MythTV Branch : exported
> Network Protocol : 63
> Library API : 0.24.20101028-1
> QT Version : 4.7.1
> Options compiled in:
> linux release using_alsa using_oss using_backend
> using_bindings_perl using_bindings_python using_dvb using_firewire
> using_frontend using_hdhomerun using_hdpvr using_iptv using_ivtv
> using_joystick_menu using_lirc using_mheg using_opengl_video
> using_opengl_vsync using_qtdbus using_qtwebkit using_v4l using_x11
> using_xrandr using_xv using_xvmc using_xvmc_vld using_xvmcw
> using_bindings_perl using_bindings_python using_mythtranscode
> using_opengl using_vdpau using_ffmpeg_threads using_live using_mheg
>
> [ ... snip ... ]
>
> (1) Recordings - I want them to be "system neutral", sans
> commericals. That is, I just want the video files, with the
> commercials removed, that I'll manage via MythVideo in the
> new system.
>
> Looks like the first step is to create a cutlist for the
> commercials. I trust the job mythcommflag did (i.e. don't want to
> manually make cut lists). Most things I read online suggest using
> mythcommflag --gencutlist. I can't figure out how to do that:
>
> $ mythcommflag --gencutlist
> 2011-07-17 12:49:23.685 Using runtime prefix = /usr
> 2011-07-17 12:49:23.685 Using configuration directory = /home/mythtv/.mythtv
> 2011-07-17 12:49:23.685 Unable to read configuration file mysql.txt
> 2011-07-17 12:49:23.685 Empty LocalHostName.
> 2011-07-17 12:49:23.690 New DB connection, total: 1
> 2011-07-17 12:49:23.703 Closing DB connection named 'DBManager0'
> 2011-07-17 12:49:23.714 No program data exists for channel 0 at
>
> [ ... snip ... ]
I still can't get mythcommflag --gencutlist to work.
However, I did some searching, and came up with a more manual way to
do what I want:
# put all the files you want to export here in the FILELIST array
export FILELIST="1321_20110409230000.mpg 1321_20110401200000.mpg"
for INFILE in $FILELIST ; do
echo -e "\n\n=== $INFILE ===" ;
export CUTLIST=`mythcommflag --getskiplist -f $INFILE \
| tail -n 1 | awk '{print $4}' | sed 's/,/ /g'` ;
export OUTFILE=`basename $INFILE .mpg`.transcode.mpg ;
mythtranscode -i $INFILE --mpeg2 --honorcutlist "$CUTLIST" \
--showprogress -o $OUTFILE ;
done
I also found that the "mythlink.pl" script is incredibly useful for
mapping the recording files to "human readable" format. E.g., on my
system I did something like this:
/usr/share/mythtv/contrib/user_jobs/mythlink.pl \
--link links/ --format '%T-%S' --underscores
There's a MythTV wiki page[1] that has the details for mythlink.
Anyway, this so far seems to work OK. Hopefully this is useful for
anyone with similar goals as me.
Thanks again,
Matt
[1] http://www.mythtv.org/wiki/Mythlink.pl
More information about the mythtv-users
mailing list