Ticket #9339: reproduce_ffmpeg_interlacing_issue.sh

File reproduce_ffmpeg_interlacing_issue.sh, 1.8 KB (added by daren, 5 years ago)
Line 
1#!/usr/bin/env bash
2
3# put these tarballs in the same directory
4# https://www.johnvansickle.com/ffmpeg/releases/ffmpeg-release-amd64-static.tar.xz -> unpacking as ...-5.0-...
5# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.4-amd64-static.tar.xz
6# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.4.1-amd64-static.tar.xz
7# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.3.2-amd64-static.tar.xz
8# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.3.1-amd64-static.tar.xz
9# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.2.2-amd64-static.tar.xz
10# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.2.1-amd64-static.tar.xz
11# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.1.4-amd64-static.tar.xz
12# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-4.0.3-64bit-static.tar.xz
13# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-3.4.2-64bit-static.tar.xz
14# https://www.johnvansickle.com/ffmpeg/old-releases/ffmpeg-3.3.4-64bit-static.tar.xz
15
16# comment this out if unpacked once
17for tb in ffmpeg*static*tar.xz; do tar -xf "${tb}"; done
18
19for f in 3.3.4 3.4.2 4.0.3 4.1.4 4.2.1 4.2.2 4.3.1 4.3.2 4.4 4.4.1 5.0; do
20 "ffmpeg-${f}-"*"/ffmpeg" -y \
21 -i "progressive_interlaced_footage.mkv" \
22 -pix_fmt yuv420p \
23 -c:v libx264 -crf 23 -preset ultrafast -flags +ilme+ildct -top 1 \
24 -profile:v high -level 4.1 \
25 -c:a ${acodec} \
26 -y \
27 "interlaced_footage_ffmpeg-${f}.mkv"
28done
29
30# play interlaced encodes with
31for f in 3.3.4 3.4.2 4.0.3 4.1.4 4.2.1 4.2.2 4.3.1 4.3.2 4.4 4.4.1 5.0; do
32 mpv --keep-open=yes --deinterlace "interlaced_footage_ffmpeg-${f}.mkv"
33done
34
35# releases up to 4.3.2 produce a proper interlaced encode from the botched progressive one
36# releases 4.4 - 5.0 screw up the field order and result in stutter when deinterlacing