Message ID | 20231210030512.866830-1-marth64@proxyid.net |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel] avformat/options_table, doc/formats: clarify meaning of igndts as per definition in avformat.h | expand |
Context | Check | Description |
---|---|---|
yinshiyou/commit_msg_loongarch64 | warning | The first line of the commit message must start with a context terminated by a colon and a space, for example "lavu/opt: " or "doc: ". |
andriy/commit_msg_x86 | warning | The first line of the commit message must start with a context terminated by a colon and a space, for example "lavu/opt: " or "doc: ". |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
On date Saturday 2023-12-09 21:05:13 -0600, Marth64 wrote: > This confused me for a long time, hopefully this is helpful to others. > The definition in avformat.h says "Ignore DTS on frames that contain both DTS & PTS" > > Signed-off-by: Marth64 <marth64@proxyid.net> > --- > doc/formats.texi | 2 +- > libavformat/options_table.h | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/doc/formats.texi b/doc/formats.texi > index 640b23b790..2ebcef50c0 100644 > --- a/doc/formats.texi > +++ b/doc/formats.texi > @@ -46,7 +46,7 @@ Enable fast, but inaccurate seeks for some formats. > @item genpts > Generate missing PTS if DTS is present. > @item igndts > -Ignore DTS if PTS is set. Inert when nofillin is set. > +Ignore DTS if PTS is also set. Inert when nofillin is set. This can be expanded a bit, my take: Ignore DTS if PTS is also set. In case the PTS is set, the DTS value is set to NOPTS. This is ignored when the @code{nofillin} flag is set. > @item ignidx > Ignore index. > @item nobuffer > diff --git a/libavformat/options_table.h b/libavformat/options_table.h > index 91708de453..4ee3fc1d81 100644 > --- a/libavformat/options_table.h > +++ b/libavformat/options_table.h > @@ -45,7 +45,7 @@ static const AVOption avformat_options[] = { > {"genpts", "generate pts", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_GENPTS }, INT_MIN, INT_MAX, D, "fflags"}, > {"nofillin", "do not fill in missing values that can be exactly calculated", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_NOFILLIN }, INT_MIN, INT_MAX, D, "fflags"}, > {"noparse", "disable AVParsers, this needs nofillin too", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_NOPARSE }, INT_MIN, INT_MAX, D, "fflags"}, > -{"igndts", "ignore dts", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_IGNDTS }, INT_MIN, INT_MAX, D, "fflags"}, > +{"igndts", "ignore dts (if pts is also set)", 0, AV_OPT_TYPE_CONST, > {.i64 = AVFMT_FLAG_IGNDTS }, INT_MIN, INT_MAX, D, "fflags"}, set DTS to NOPTS value in case PTS is set ?
diff --git a/doc/formats.texi b/doc/formats.texi index 640b23b790..2ebcef50c0 100644 --- a/doc/formats.texi +++ b/doc/formats.texi @@ -46,7 +46,7 @@ Enable fast, but inaccurate seeks for some formats. @item genpts Generate missing PTS if DTS is present. @item igndts -Ignore DTS if PTS is set. Inert when nofillin is set. +Ignore DTS if PTS is also set. Inert when nofillin is set. @item ignidx Ignore index. @item nobuffer diff --git a/libavformat/options_table.h b/libavformat/options_table.h index 91708de453..4ee3fc1d81 100644 --- a/libavformat/options_table.h +++ b/libavformat/options_table.h @@ -45,7 +45,7 @@ static const AVOption avformat_options[] = { {"genpts", "generate pts", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_GENPTS }, INT_MIN, INT_MAX, D, "fflags"}, {"nofillin", "do not fill in missing values that can be exactly calculated", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_NOFILLIN }, INT_MIN, INT_MAX, D, "fflags"}, {"noparse", "disable AVParsers, this needs nofillin too", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_NOPARSE }, INT_MIN, INT_MAX, D, "fflags"}, -{"igndts", "ignore dts", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_IGNDTS }, INT_MIN, INT_MAX, D, "fflags"}, +{"igndts", "ignore dts (if pts is also set)", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_IGNDTS }, INT_MIN, INT_MAX, D, "fflags"}, {"discardcorrupt", "discard corrupted frames", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_DISCARD_CORRUPT }, INT_MIN, INT_MAX, D, "fflags"}, {"sortdts", "try to interleave outputted packets by dts", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_SORT_DTS }, INT_MIN, INT_MAX, D, "fflags"}, {"fastseek", "fast but inaccurate seeks", 0, AV_OPT_TYPE_CONST, {.i64 = AVFMT_FLAG_FAST_SEEK }, INT_MIN, INT_MAX, D, "fflags"},
This confused me for a long time, hopefully this is helpful to others. The definition in avformat.h says "Ignore DTS on frames that contain both DTS & PTS" Signed-off-by: Marth64 <marth64@proxyid.net> --- doc/formats.texi | 2 +- libavformat/options_table.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)