diff thesis/to-frames.pl @ 441:c20de2267d39

completeing first third of first chapter.
author Robert McIntyre <rlm@mit.edu>
date Mon, 24 Mar 2014 20:59:35 -0400
parents
children
line wrap: on
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/thesis/to-frames.pl	Mon Mar 24 20:59:35 2014 -0400
     1.3 @@ -0,0 +1,15 @@
     1.4 +#!/bin/perl
     1.5 +
     1.6 +$movie_file = shift(@ARGV);
     1.7 +
     1.8 +# get file name without extension
     1.9 +$movie_file =~ m/^([^.]+)\.[^.]+$/;
    1.10 +$movie_name = $1;
    1.11 +
    1.12 +@mkdir_command = ("mkdir", "-vp", $movie_name);
    1.13 +@ffmpeg_command = ("ffmpeg", "-i", $movie_file, $movie_name."/%07d.png");
    1.14 +
    1.15 +print "@mkdir_command\n";
    1.16 +system(@mkdir_command);
    1.17 +print "@ffmpeg_command\n";
    1.18 +system(@ffmpeg_command);
    1.19 \ No newline at end of file