Welcome Guest, Not a member yet? Register   Sign In
FFMPEG Convertion Library... HELP!
#6

[eluser]darkhouse[/eluser]
Here's the conversion command I'm using, and I'll show you how I get the video dimensions using ffmpeg_movie:

Code:
$srcFile = 'someFile.mpg';
$destFile = 'someFile.flv';

$ffmpegObj = new ffmpeg_movie($srcFile);
        
$srcWidth = $ffmpegObj->getFrameWidth();
$srcWidth -= $srcWidth & 1;
            
$srcHeight = $ffmpegObj->getFrameHeight();
$srcHeight -= $srcHeight & 1;

$srcSize = $srcWidth.'x'.$srcHeight;

exec("ffmpeg -i {$srcFile} -sameq -acodec libmp3lame -ar 22050 -ab 32 -f flv -s {$srcSize} {$destFile}");

This code works great for me, hopefully it works for you as well.


Messages In This Thread
FFMPEG Convertion Library... HELP! - by El Forum - 08-11-2007, 06:11 AM
FFMPEG Convertion Library... HELP! - by El Forum - 02-24-2009, 06:09 AM
FFMPEG Convertion Library... HELP! - by El Forum - 02-24-2009, 07:10 AM
FFMPEG Convertion Library... HELP! - by El Forum - 02-24-2009, 07:17 AM
FFMPEG Convertion Library... HELP! - by El Forum - 02-24-2009, 05:11 PM
FFMPEG Convertion Library... HELP! - by El Forum - 02-24-2009, 07:40 PM
FFMPEG Convertion Library... HELP! - by El Forum - 03-09-2009, 05:56 AM
FFMPEG Convertion Library... HELP! - by El Forum - 03-19-2009, 12:06 AM



Theme © iAndrew 2016 - Forum software by © MyBB