Category: | GUI Programming |
Author/Contact Info | zentara of perlmonks |
Description: | Want to make a highly succesful how-to to put on You-Tube? Or maybe speed up looking thru your security camera still images? Here you go....put a sequential list of jpg's in a subdir, and run this script on it. The output flv is conveniently named as 111****.flv so as to be at the top of your dir list. :-) A sample of me fixing a lamp is lamp_fix |
#!/usr/bin/perl use warnings; use strict; # Usage: $0 'a_video_subdir_full_of_sequential_jpgs' $|++; my $videodir = shift || 'lamp_fix'; #put the video at the top of the long image list my $video = $videodir.'/111'.$videodir.'.flv'; # recombine recombine(); print "done\n"; exit; ################################################### sub recombine{ opendir my $dh, $videodir or die "Error: $!\n"; my @files = grep !/^\.\.?$/, readdir $dh; @files = grep /^(.*)\.jpg$/, @files; closedir $dh; #print "@files\n"; #audio options left in just incase you want to try adding audio my @moptions =( 'mencoder', "mf://$videodir/*.jpg", '-mf', 'fps=29.97', #NTSC tv video rate in # '-audiofile', "$base.wav", '-srate', 22050, '-o', $video, '-ovc', 'lavc', '-lavcopts', 'vcodec=mpeg4:vbitrate=100', # '-oac', 'mp3lame', # '-audio-delay', 0.2, #adjust for audio syncing problems ); system(@moptions); } ############3 |
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Recombine still image sequences into movies
by grinder (Bishop) on Feb 25, 2009 at 19:42 UTC | |
by zentara (Archbishop) on Feb 25, 2009 at 20:14 UTC | |
by grinder (Bishop) on Feb 25, 2009 at 21:25 UTC | |
by zentara (Archbishop) on Feb 26, 2009 at 13:46 UTC | |
Re: Recombine still image sequences into movies
by puudeli (Pilgrim) on Feb 26, 2009 at 08:27 UTC | |
Re: Recombine still image sequences into movies
by zentara (Archbishop) on Feb 26, 2009 at 13:43 UTC | |
Re: Recombine still image sequences into movies
by Lawliet (Curate) on Feb 25, 2009 at 20:32 UTC |
Back to
Code Catacombs