[FFmpeg-user] '-bsf setts=dts' has problems
Paul B Mahol
onemda at gmail.com
Sat Jun 8 12:29:25 EEST 2024
On Sat, Jun 8, 2024 at 8:36 AM Mark Filipak <markfilipak.imdb at gmail.com>
wrote:
> '-bsf setts=pts' seems to always work, but '-bsf setts=dts' has problems.
> Look:
>
It is evident that you never looked at actual setts documentation.
# ffmpeg -h bsf=setts
ffmpeg version N-115950-g1f63f014ff Copyright (c) 2000-2024 the FFmpeg
developers
built with clang version 17.0.6
configuration: --cc='ccache clang' --as='ccache clang' --disable-indevs
--disable-outdevs --disable-autodetect --enable-sdl2 --enable-gpl
--enable-indev=lavfi --enable-indev=alsa --enable-outdev=alsa
--enable-nonfree --enable-zlib --enable-openssl --disable-static
--enable-shared --enable-clap --enable-ladspa --enable-libflite
--enable-lv2 --enable-version3 --enable-libmp3lame --enable-libmysofa
--enable-libx264 --enable-fontconfig --enable-libfreetype --enable-libass
--enable-librubberband --enable-libzimg --enable-libharfbuzz
--disable-stripping --disable-htmlpages --enable-libsoxr
--samples=../fate-suite
libavutil 59. 21.100 / 59. 21.100
libavcodec 61. 6.100 / 61. 6.100
libavformat 61. 3.104 / 61. 3.104
libavdevice 61. 2.100 / 61. 2.100
libavfilter 10. 2.102 / 10. 2.102
libswscale 8. 2.100 / 8. 2.100
libswresample 5. 2.100 / 5. 2.100
Bit stream filter setts
setts_bsf AVOptions:
-ts <string> ...VAS..B.. set expression for packet PTS
and DTS (default "TS")
-pts <string> ...VAS..B.. set expression for packet PTS
-dts <string> ...VAS..B.. set expression for packet DTS
-duration <string> ...VAS..B.. set expression for packet
duration (default "DURATION")
-time_base <rational> ...VAS..B.. set output timebase (from 0
to INT_MAX) (default 0/1)
>
> C:\Windows\System32>ffmpeg -copyts -i "g:\FANNY AND ALEXANDER
> [1982(1983)]\00305.m2ts" -map 0
> -bsf noise=drop='lt(pts\,2854113)'
> -c copy -sn -dn -muxdelay 0 "g:\FANNY AND ALEXANDER [1982(1983)]\foo.m2ts"
> 0, 2846606, 2854113, 3753, 640646, 0x3a5a0c45, S=1, 1
> 0, 2854113, 2861621, 3753, 640646, 0x02208727, F=0x0, S=1,
> 1
>
> C:\Windows\System32>ffmpeg -copyts -i "g:\FANNY AND ALEXANDER
> [1982(1983)]\00305.m2ts" -map 0
> -bsf
> noise=drop='lt(pts\,2854113)',setts=dts='if(eq(DTS\,2846606)\,2850360\,DTS)'
> -c copy -sn -dn -muxdelay 0 "g:\FANNY AND ALEXANDER [1982(1983)]\foo.m2ts"
> The command provokes this: "Invalid DTS: 2850360 PTS: 2846606, replacing
> by guess"
> 0, 2846606, 2846606, 3753, 640646, 0x3a5a0c45, S=1, 1
> 0, 2854113, 2854113, 3753, 640646, 0x02208727, F=0x0, S=1,
> 1
> There is nothing invalid with DTS: 2850360 if PTS is 2854113, but FFmpeg
> appears to change PTS on
> it's own, without a command to do it.
>
> The second command should not change PTSes, but it does. In fact, all
> frame PTSes are being set to
> their DTSes.
>
> I have documented a litany of DTS problems now. Are they being taken
> seriously?
>
> This is unrelated to my investigation of splices and my search for a
> workaround because of FFmpeg's
> inability to set MPEG tag 'closed_gop' to '1'. Or maybe it is related, I
> have no way to know.
>
> Will someone please work with me so I can share the source with them so
> they can verify what I'm
> seeing? I cannot continue to work alone on this. It's just too nerve
> wracking.
>
Nobody can take you and your mails seriously.
> --Mark.
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
>
More information about the ffmpeg-user
mailing list