So I've been working on trying to get FFMPEG to encode videos that are uploaded to my site. The upload script calls the PHP binary using exec() to run a script called encode.php that looks like this:
include("include/config.inc.php");
$videoID = $argv[1];
exec("ffmpeg -i " . $_SERVER['DOCUMENT_ROOT'] . "/processing/" . $videoID. ".mp4 -vcodec libx264 -vpre normal -s 1280x720 -r 30 -acodec libfaac " . $_SERVER['DOCUMENT_ROOT'] . "/videos/" . $videoID . ".mp4");
$connect = mysql_connect($dbhost, $dbusername, $dbpassword);
mysql_select_db($dbname, $connect);
$query = mysql_query("UPDATE `videos` SET `isProcessing` = 0 WHERE `id` = '$videoID' LIMIT 1");
However, nothing happens to the video at all. I've tried using the full path to FFMPEG, but that doesn't work either. I know the script is being executed as the isProcessing is set to 0 in the database.
Maybe I'm just clueless, but I can't seem to figure this out. Any help would be greatly appreciated.