[FFmpeg-user] 'image trails'

Mark Filipak markfilipak.windows+ffmpeg at gmail.com
Wed Apr 8 05:48:27 EEST 2020

Start again after a good sleep.

Re: https://ffmpeg.org/pipermail/ffmpeg-user/attachments/20200407/4556ce6a/attachment.mpv

Kindly play 'attachment'. Got any ideas what's causing the image trails?

fmpeg -i "M:\Test Videos\23.976p.mkv" \
-filter_complex \
"telecine=pattern=5 \
,split=3[B][C][D] \
,[B]select='bitand(not(eq(mod(n+1\,10)\,3))\,not(eq(mod(n+1\,10)\,8)))'[E] \
,[C]select='eq(mod(n+1\,10)\,3)'[G] \
,[D]select='eq(mod(n+1\,10)\,8)'[H] \
,[E][G][H]mix=3" \
-map 0 -c:v libx264 -crf 28 -c:a copy -c:s copy "C:\AVOut\23.976p.MKV"


                                   > select=/*  else   */ >
IN --> telecine=pattern=5 > split > select=/*n+1%10==3*/ > mix > attachment
                                   > select=/*n+1%10==8*/ >

The top 'select' should block (zero-based) frames 2 7 12 17 etc.
The mid 'select' should pass (zero-based) frames 2 12 etc.
The bot 'select' should pass (zero-based) frames 7 17 etc.
'mix' should put the 3 streams back together.

Of course, the mix (i.e., 'attachment') should be the same as 'IN', but it's not. From playing back 
'attachment', and based on your much greater experience, do you see anything to explain it?

The video is actually an MKV. It's best viewed via MPV player (https://mpv.io/installation/) because 
MPV player facilitates single-frame stepping.

Sorry for the mixup -- I was awfully tired and I was trying a great many command lines in quick 
succession (e.g., 'n modulo 9 == 2', 'n+1 modulo 10 == 3', and the various modulos in various 

Thanks for your attention. This is making me a little crazy.


More information about the ffmpeg-user mailing list