Home >php教程 >PHP源码 >使用 memcoder 将视频转成 mp4 格式 (x264)

使用 memcoder 将视频转成 mp4 格式 (x264)

PHP中文网
PHP中文网Original
2016-05-25 17:14:461846browse

使用 memcoder 将视频转成 mp4 格式 (x264)

<?php
convertTo( "some-input-video.avi", "output.mp4" );
 
function convertTo( $input, $output ) {
   echo "Converting $input to $output<br />";
   $command = "mencoder $input -o $output -af volume=10 -aspect 16:9 -of avi -noodml -ovc x264 
   -x264encopts bitrate=500:level_idc=41:bframes=3:frameref=2: nopsnr: nossim: pass=1: threads=auto
    -oac mp3lame";
   echo "$command<br />";
   shell_exec( $command );
   echo "Converted<br />";
}
?>

以上就是使用 memcoder 将视频转成 mp4 格式 (x264)的内容,更多相关内容请关注PHP中文网(www.php.cn)!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn