ffmpeg encoder optimization

来源:互联网 发布:近景摄影测量软件 编辑:程序博客网 时间:2024/06/07 21:55
    //Added by Ken on April 12,2016
av_dict_set(&opt, "preset", "veryfast", 0);
av_dict_set(&opt, "crf", "25", 0);
//The range of the quantizer scale is 0-51: where 0 is lossless, 23 is default, and 51 is worst possible. A lower value is a higher 
//quality and a subjectively sane range is 18-28. Consider 18 to be visually lossless or nearly so: it should look the same or nearly 
//the same as the input but it isn't technically lossless.

av_dict_set(&opt, "movflags", "faststart", 0);
av_dict_set(&opt, "tune", "zerolatency", 0);
av_dict_set(&opt, "pixfmt", "yuv420p", 0);
av_dict_set(&opt, "x264opts", "bframes0:keyint_min=25:keyint=100", 0);
av_dict_set(&opt, "c:v", "libx264", 0);
av_dict_set(&opt, "subq", "1", 0);

//av_dict_set(&opt, "s", std::to_string(dst_width)+"x"+std::to_string(dst_height), 0);



0 0
原创粉丝点击