打造一个属于自己的转换软件——FFMPEG

最近一年开始使用FFmpeg这个软件,速度与质量都是没得说。。

最近因为电脑经常换,就很不方便,在32位及64位系统之间存在很大的问题。。

针对遇到的这些问题,将FFMPEG进行了改进~~

REM mp4  (H.264 / ACC)

IF "%PROCESSOR_ARCHITECTURE%"=="AMD64" (GOTO J64) ELSE (GOTO J32)

:J64
"%~dp0\bin\ffmpeg.exe" -y -i %1 -vcodec libx264 -vprofile high -preset slow -b:v 15000k -maxrate 17000k -bufsize 1000k -vf scale=trunc(oh*a/2)*2:480 -r 25 -threads 0 -acodec libvo_aacenc -b:a 192k %1.mp4
goto END

:J32
"%~dp0\bin\ffmpeg32.exe" -y -i %1 -vcodec libx264 -vprofile high -preset slow -b:v 15000k -maxrate 17000k -bufsize 1000k -vf scale=trunc(oh*a/2)*2:480 -r 25 -threads 0 -acodec libvo_aacenc -b:a 192k %1.mp4
goto END

:END
exit

再来个批量添加水印的!

转换代码(水印与需要转换的视频放置在同一目录)

@TITLE Conversion To Mp4

IF "%PROCESSOR_ARCHITECTURE%"=="AMD64" (GOTO J64) ELSE (GOTO J32)

:J64
"%~dp0\bin\ffmpeg.exe" -y -i %1 -vcodec libx264 -vprofile high -preset slow -b:v 2000k -maxrate 2700k -bufsize 1000k -vf "movie=watermark.png [logo];[in][logo] overlay=main_w-overlay_w-50:main_h-overlay_h-100 [out]" -threads 0 -acodec libvo_aacenc -b:a 192k %1.mp4
goto END

:J32
"%~dp0\bin\ffmpeg32.exe" -y -i %1 -vcodec libx264 -vprofile high -preset slow -b:v 2000k -maxrate 2700k -bufsize 1000k -vf "movie=watermark.png [logo];[in][logo] overlay=main_w-overlay_w-50:main_h-overlay_h-100 [out]" -threads 0 -acodec libvo_aacenc -b:a 192k %1.mp4
goto END

:END
exit

There are no comment yet.

HTML tag cannot be used in this comment.