[FFmpeg-user] '-bsf setts=dts' has problems
Mark Filipak
markfilipak.imdb at gmail.com
Sat Jun 8 19:44:59 EEST 2024
On 08/06/2024 12.05, Paul B Mahol wrote:
-snip-
> If you do not explicitly set expression for both pts and dts options, they
> will be set to same value later.
Thank you, Paul. I see (and I'm surprised by it).
So this command:
-bsf setts=dts='if(eq(DTS\,2846606)\,2850360\,DTS)'
produces this:
0, 2846606, 2846606, 3753, 640646, 0x3a5a0c45,
0, 2854113, 2854113, 3753, 640646, 0x02208727,
(which is not intended and surprises me),
whereas this command:
-bsf setts=dts='if(eq(DTS\,2846606)\,2850360\,DTS)':pts=PTS
produces this:
0, 2850360, 2854113, 3753, 640646, 0x3a5a0c45,
0, 2854113, 2861621, 3753, 640646, 0x02208727,
(which is correct and what I intended).
So, PTSes can be rewritten, but DTSes cannot be rewritten unless PTSes are copied in the same setts.
Therefore, the scope of setts=pts is only PTSes, but the scope of setts=dts is both DTSes & PTSes.
That's illogical.
It's also contrary to what the documentation says:
"Set expressions for PTS, DTS or both"
Nevertheless, you have really helped me. I thank you!
--Mark.
More information about the ffmpeg-user
mailing list