[FFmpeg-trac] #7092(undetermined:new): h264 parser emits every other video packet without pts for mbaff/paff inputs

FFmpeg trac at avcodec.org
Sat Jun 16 03:24:28 EEST 2018


#7092: h264 parser emits every other video packet without pts for mbaff/paff
inputs
-------------------------------------+-------------------------------------
             Reporter:  tmm1         |                    Owner:
                 Type:  defect       |                   Status:  new
             Priority:  normal       |                Component:
              Version:  git-master   |  undetermined
             Keywords:               |               Resolution:
             Blocking:               |               Blocked By:
Analyzed by developer:  0            |  Reproduced by developer:  0
-------------------------------------+-------------------------------------

Comment (by tmm1):

 I discovered that I can fix the ffprobe output by telling the mpegts
 demuxer not to parse H264 streams:

 {{{
 diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c
 index 76d5bbb920..5fca4e822a 100644
 --- a/libavformat/mpegts.c
 +++ b/libavformat/mpegts.c
 @@ -894,6 +894,9 @@ static int mpegts_set_stream_info(AVStream *st,
 PESContext *pes,
          st->codecpar->codec_id   = AV_CODEC_ID_BIN_DATA;
          st->request_probe = AVPROBE_SCORE_STREAM_RETRY / 5;
      }
 +    if (st->codecpar->codec_id == AV_CODEC_ID_H264) {
 +        st->need_parsing = AVSTREAM_PARSE_HEADERS;
 +    }

      /* queue a context update if properties changed */
      if (old_codec_type != st->codecpar->codec_type ||
 }}}

 However, then there are problems decoding the video for some reason.

--
Ticket URL: <https://trac.ffmpeg.org/ticket/7092#comment:2>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list