胡斌

adjust default video codec param,using cfr,frame rate 20 and key frame interval 100

... ... @@ -66,7 +66,7 @@ cat 0.ts 1.ts 2.ts 3.ts 4.ts 5.ts 6.ts 7.ts 8.ts> m.ts ;linux
ffmpeg -y -i m.ts -acodec copy -vcodec copy dest.ts
调用ffmpeg时,视频编码参数是: -vcodec libx264 -level 3.1 -preset veryfast -g 40 -r 20
调用ffmpeg时,视频编码参数是: -vcodec libx264 -level 3.1 -preset veryfast -g 100 -r 20 -bf 0 -vsync cfr
音频编码参数是: -acodec copy
如果要修改,windows下在merge_av.exe同目录下新建merge_av.cfg文本文件,第一行保存视频编码,第二行保存音频编码;linux 下,merge_av.cfg保存在HOME目录下的merge_av目录。
... ...
... ... @@ -69,7 +69,7 @@ void get_config_path(){
#endif
}
const char * default_vcodec_param = "-vcodec libx264 -level 3.1 -preset veryfast -g 40 -r 20";
const char * default_vcodec_param = "-vcodec libx264 -level 3.1 -preset veryfast -g 100 -r 20 -bf 0 -vsync cfr";
const char * default_acodec_param = "-acodec copy";
char vcodec_param[1024];
... ... @@ -503,7 +503,7 @@ void load_codec_param()
int main(int argc, char * argv[])
{
if (argc < 2) {
printf(" merge_av 1.0.0\n");
printf(" merge_av 1.0.2\n");
printf(" run ffmpeg to merge audio and video files according to the record info file,\nusage:");
printf("\n %s record_info_filename [-p] [-k]", argv[0]);
printf("\n -p :only print the command,don't run ffmpeg");
... ...