On Thu, Nov 24, 2011 at 12:06, Carl Eugen Hoyos <ceho...@ag.or.at> wrote: > Camera Man <i.like.privacy.too@...> writes: > >> would it work to patch ff_h264_decode_init() and decode_postinit() to also >> check the AV_DISCARD mode, and if we are discarding B and/or nonref frames, >> would set avctx->has_b_frames=0 and low_delay=1 ? > > I don't know but I suggest that you write such a patch (optionally test it on > streams with B-frames) and post it on ffmpeg-devel where it can be discussed.
Maybe I am missing something, but if you discard B frames you may have problems with the P frames that follow (and that until you get the next I frame). Also, note that the codecs check avctx->skip_loop_filter not as bitfield, but priority. Thus, AVDISCARD_BIDIR means also AVDISCARD_NONREF, which is probably not what you want. I believe that the correct way to fix is to modify SPS/PPS, because these are simply wrong in your case. BR, Alex Cohn _______________________________________________ Libav-user mailing list Libav-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/libav-user