- 方法一
c->max_b_frames = 0;
ret = avcodec_open2(c, codec, NULL);
- 方法二
AVDictionary *d = NULL;
av_dict_set_int(&d,"bf",0,0);
ret = avcodec_open2(c, codec, &d);
- 方法三
AVDictionary *d = NULL;
av_dict_set(&d,"x264opts","bframe=0",0); //实际验证未成功,todo
ret = avcodec_open2(c, codec, &d);