> 2021年12月29日 下午2:59,zozobreak <zozobr...@163.com> 写道: > > since there is only debug log 'no picture ooo' when droping a picture, > I spent much time to troubleshooting a wrong sps 'num_reorder_frames' param > changed by webrtc's 'ParseAndRewriteSps', > FFmpeg keeped silence about this error, so a warning log is much helpfull > about this. > > > > > Signed-off-by: zourenyi <zozobr...@163.com> > --- > libavcodec/h264_slice.c | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-) > > > > > diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c > index c21004df97..f8bf8fe36e 100644 > --- a/libavcodec/h264_slice.c > +++ b/libavcodec/h264_slice.c > @@ -1533,7 +1533,14 @@ static int h264_select_output_frame(H264Context *h) > } > } > } else { > - av_log(h->avctx, AV_LOG_DEBUG, "no picture %s\n", out_of_order ? > "ooo" : ""); > + if (out_of_order) { > + av_log(h->avctx, AV_LOG_WARNING, > + "drop picture(%c, %d) because of ooo\n", > + av_get_picture_type_char(out->f->pict_type), out->poc); > + } > + else { You shoulf fix code style, otherwise is ok. > + av_log(h->avctx, AV_LOG_DEBUG, "no picture\n"); > + } > } > return 0; > -- > 2.32.0.windows.2 > > <0001-avcodec-libx264-add-warning-log-when-droping-picture.patch>_______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
Thanks Steven Liu _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".