[FFmpeg-devel] [PATCH] mark null encoder as ts-nonstrict , avoids error messages for null output

Hendrik Leppkes h.leppkes at gmail.com
Thu Aug 21 14:00:22 CEST 2014


On Thu, Aug 21, 2014 at 1:38 PM, compn <tempn at mi.rr.com> wrote:
> https://gist.github.com/anonymous/0e26f490ec13d67996fd
>
> commit e94a44543a96b13aa6a23efce2f0378a5479d530
> Author: Rodger Combs <rodger.combs at gmail.com>
> Date:   Wed Aug 20 15:38:12 2014 -0700
>
>     avformat/nullenc: mark null as timestamp-nonstrict
>     This avoids unnecessary error messages for null output
>
> diff --git a/libavformat/nullenc.c b/libavformat/nullenc.c
> index 7c08c39..58b88a1 100644
> --- a/libavformat/nullenc.c
> +++ b/libavformat/nullenc.c
> @@ -32,5 +32,5 @@ AVOutputFormat ff_null_muxer = {
>      .audio_codec       = AV_NE(AV_CODEC_ID_PCM_S16BE, AV_CODEC_ID_PCM_S16LE),
>      .video_codec       = AV_CODEC_ID_RAWVIDEO,
>      .write_packet      = null_write_packet,
> -    .flags             = AVFMT_VARIABLE_FPS | AVFMT_NOFILE | AVFMT_NOTIMESTAMPS | AVFMT_RAWPICTURE,
> +    .flags             = AVFMT_TS_NONSTRICT | AVFMT_VARIABLE_FPS | AVFMT_NOFILE | AVFMT_NOTIMESTAMPS | AVFMT_RAWPICTURE,
>  };

There is a lot of other muxers out there that also have NOTIMESTAMPS
set, and not this flag.

IMHO the code that complains about invalid timestamps should be
adjusted to not do it when NOTIMESTAMPS is set, instead of this.


More information about the ffmpeg-devel mailing list