[FFmpeg-user] FFMpeg problem using fieldmatch and decimate filters to IVTC

David Favor david at davidfavor.com
Mon Jul 21 16:37:44 CEST 2014


Steve Boyer wrote:
> Hey all,
> 
> Originally, I posted this to the wrong mailing list and had a request to
> execute an ffprobe command. I am reposting and including the output of the
> commands.
> 
> The ffprobe.txt file is for the sample.vob and the ffprobe.4.18.txt is for
> the full, ~2GB vob.
> 
> I'm trying to encode a large number of videos so I can watch them on my
> phone, but not having luck doing a proper IVTC using the fieldmatch and
> decimate filters. I have compiled from source yesterday afternoon as
> outlined on https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu. Using the
> command:
> 
> ffmpeg -i 4.18 -map 0:1 -map 0:3 -vf crop=704:480:10:0 -vf
> fieldmatch,decimate -c:v libx264 -preset veryfast -level 41 -crf 22 -c:a
> libfdk_aac -t 360 4.18.fieldmatch.decimate.mp4

Hum...

I notice your matching a different set of streams, than I'd use.

For example, in your container the 0:1 audio stream is out of sync with the
video... Maybe the more recent version of ffmpeg I'm using maps streams slightly
different. Here's what I used to create crystal clear output with audio/video in sync...

David-Favor-iMac> avinfo long.sample.vob
long.sample.vob
    length: 26:24:22.11, start: 611.204267, bitrate: 17 kb/s
    stream: #0:0[0x1e0]: Video: mpeg2video (Main), yuv420p(tv, smpte170m), 720x480 [SAR 8:9 DAR 4:3], max. 9800 kb/s, 29.83 fps, 59.94 tbr, 90k tbn, 59.94 tbc
    stream: #0:1[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 448 kb/s
    stream: #0:2[0x81]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s

So I'm using 0:0 as video + 0:2 as audio (as 0:2 is in sync with video)...

    nice -n 20 ffmpeg -i 'long.sample.vob' -map 0:0 -map 0:2 \
         -c:a libfdk_aac -b:a 128k -ac 2 -ar 44100 \
         -c:v libx264 -crf:v 22 -preset:v veryfast -tune:v film -level:v 4.1 -profile:v high -r 23.976 sample.mp4


Using the default fps of 29.97 produced 1000s of duplicate frames, so
I added -r 23.976 as it appears original footage was recorded at this fps.

Either way footage plays well + with -r 23.976 compresses by around 80%
with no additional filters.

Maybe this helps.


More information about the ffmpeg-user mailing list