[mythtvnz] Cutting H.264 DVB-T files with ffmpeg without transcoding
Ross and Jemima Knudsen
ross.jemima at gmail.com
Sat Jul 24 10:02:56 BST 2010
On 24/07/2010 12:38 p.m., David Moore wrote:
>
> I've used VB a fair bit also but I don't think it's a good idea to rely
> on something which isn't pretty standard in Ubuntu for portability
> reasons. Turns out sql in bash is really simple. Just echo the sql
> commands through a pipe to mysql and catch the results. Dead easy. :-)
> Hardest thing will be understanding which tables need updating.
> Recordedseek and recordedmarkup are the ones I know of so far.
>
You'd just want to drop all the markings for the particular recording
after doing any of the transcoding as potentially the timestamps may be
altered. So something like:
'delete from `recordedmarkup` where `chanid` = X and `starttime` = Y'
and 'delete from `recordedseek` where `chanid` = X and `starttime` = Y
http://www.mythtv.org/wiki/Recordedmarkup_table
http://www.mythtv.org/wiki/Recordedseek_table
To fix the entries in the seek table just take the lazy way out and use
one of the methods here:
http://www.mythtv.org/wiki/Repairing_the_Seektable
PS I thought that mono libraries were installed as default on Ubuntu?...
> Actually looks like the trickiest thing is handling the cuts. Myth cuts
> in recordedmarkup table are in frames whereas ffmpeg uses times so need
> to do some maths to convert frame to time. Bash doesn't do floating
> point maths but there is a linux utility called bc to do this so that's
> no problem. Could be a problem with cut accuracy however. I had a look
> at one of my recordings last night and it seems that the time myth shows
> for the cut points is not exactly equal to the cut point frame number x
> 25 (fps). I'm guessing there might be some issue with the start time for
> the recording but not sure yet.
>
>
Maybe using Avidemux might be feasible if you can get it to work on the
commandline. It uses frame numbers (I believe).
More information about the mythtvnz
mailing list