summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJarle Bjørgeengen <jarle@bjorgeengen.net>2010-09-23 07:05:13 +0000
committerJarle Bjørgeengen <jarle@bjorgeengen.net>2010-09-23 07:05:13 +0000
commitada6d9bfee93296eecfa968804f8ff95eac1b2cb (patch)
tree0a76281667cafa0193857d5e15c0a7f395416e26
parent1948ca392633b8495398a5158a05e988c097817d (diff)
Archive front- and end-poster
-rwxr-xr-xtools/gen_frikanalen_video.pl10
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/gen_frikanalen_video.pl b/tools/gen_frikanalen_video.pl
index d5a4fbe..d8add7d 100755
--- a/tools/gen_frikanalen_video.pl
+++ b/tools/gen_frikanalen_video.pl
@@ -249,12 +249,22 @@ sub glue_dv {
my $ffmpeg = "ffmpeg -i $workdir/complete.dv -aspect 16:9 -acodec pcm_s16le -vcodec dvvideo -y ".$outfile.' -f avi' ;
if ( $f eq -1 ) { die "Failed to execute system command in" . (caller(0))[3] ."\n"; }
# my $cmd = 'cat '.join(' ',@infiles).' | dvgrab -size 0 -stdin -f dv2 -opendml '.$outfile ;
+ savetemp();
if ( -d $workdir ) {
`rm -rf $workdir`;
}
}
+sub savetemp {
+ my $outfile_base = $opts{'o'};
+ $outfile_base =~ s/.+\.avi$//;
+ my $f = `mv $workdir/startposter.dv $outfile_base-starposter.dv|| echo -n -1`;
+ if ( $f eq -1 ) { die "Failed to execute system command in" . (caller(0))[3] ."\n"; }
+ $f = `mv $workdir/endposter.dv $outfile_base-endposter.dv|| echo -n -1`;
+ if ( $f eq -1 ) { die "Failed to execute system command in" . (caller(0))[3] ."\n"; }
+}
+
sub getsrtfile {
my $base = $opts{'i'};
$base =~ s/\..+$//; # Could be .dv or .avi or whatnot. This strips it off anyway.