\n";
echo "
\n";
//run this from the command line as 'php vlog_public.php'
//phpinfo();
//ipath is input path - can be DVD or harddrive location
//set ipath to where ever all the AVIs from the digital camera are to be compressed to flv for the flash player
//opath will be a local mirror with all the compressed videos sorted by yyyy/mm/dd
//$ipath='/root/videos/web200711/';
//$ipath='/mnt/dvd/';
$ipath='/home/camera/';
//$opath='/root/videos/web200711/';
$opath='/root/videos/';
//convert all folders and files from DVD (or harddrive)
if (1) { //use to test command-line
//if ($_POST["send"]=="Process videos") {
echo 'Importing and converting videos:
';
flush();
//ob_flush();
//startfile=
//=filename, do not mencoder .avi files until filename preg_matches,
//''=mencoder all .avi files,
//'0'=mencoder no .avi files
$startavifile='';//'massmentum';//bell_in_vacuum';//'music_go';
$startfile='';//';//vlog20071226-2157';
//because process_videos is recursive, we need to write the startfile variables to a file
$fp=fopen($opath.'startfile.txt',"w");
if (strlen($startfile)==0) {
fwrite($fp,"0");
} else {
fwrite($fp,$startfile);
}
fclose($fp);
$fp=fopen($opath.'startavifile.txt',"w");
if (strlen($startavifile)==0) {
fwrite($fp,"0");
} else {
fwrite($fp,$startavifile);
}
fclose($fp);
process_videos($ipath,$opath);
} else {
echo '
';
echo '';
}
echo "\n";
echo "