[FFmpeg-user] How to reduce interlace artifacts while trancoding to mp4
Ulf Zibis
Ulf.Zibis at CoSoCo.de
Sat Nov 12 02:46:15 EET 2022
Hi,
I have transcoded a avi video to mp4 for compressing by factor 8. Now I see interlace artifacts. E.g. the eagle in the back window of the bus or the fence in the background.
Additionally I would like to reduce the noise for even better compression. Any hint for a good filter?
Refer:
http://jugkoeln.de/Videos/2012-01-03_21.46.40_6.29GB_15.avi
http://jugkoeln.de/Videos/2012-01-03_21.46.40_6.29GB_15.mp4
$ ffmpeg -t 15 -i 2012-01-03_21.46.40_6.29GB_15.avi 2012-01-03_21.46.40_6.29GB_15.mp4
ffmpeg version 5.1.2-0ubuntu1~22.04.sav1 Copyright (c) 2000-2022 the FFmpeg developers
built with gcc 11 (Ubuntu 11.2.0-19ubuntu1)
configuration: --prefix=/usr --extra-version='0ubuntu1~22.04.sav1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-lcms2 --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-libzmq
--enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-sndio --enable-pocketsphinx --enable-librsvg --enable-libjxl --enable-librist --enable-libvmaf --enable-crystalhd --enable-libmfx --enable-libsvtav1 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-libplacebo --enable-librav1e --enable-shared
WARNING: library configuration mismatch
avcodec configuration: --prefix=/usr --extra-version='0ubuntu1~22.04.sav1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-lcms2 --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg
--enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-sndio --enable-pocketsphinx --enable-librsvg --enable-libjxl --enable-librist --enable-libvmaf --enable-crystalhd --enable-libmfx --enable-libsvtav1 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-libplacebo --enable-librav1e --enable-shared --enable-version3 --disable-doc --disable-programs --enable-libaribb24 --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libtesseract --enable-libvo_amrwbenc --enable-libshaderc --enable-liblensfun --enable-libsmbclient
avfilter configuration: --prefix=/usr --extra-version='0ubuntu1~22.04.sav1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-lcms2 --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg
--enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --enable-sndio --enable-pocketsphinx --enable-librsvg --enable-libjxl --enable-librist --enable-libvmaf --enable-crystalhd --enable-libmfx --enable-libsvtav1 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-libplacebo --enable-librav1e --enable-shared --enable-version3 --disable-doc --disable-programs --enable-libaribb24 --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libtesseract --enable-libvo_amrwbenc --enable-libshaderc --enable-liblensfun --enable-libsmbclient
libavutil 57. 28.100 / 57. 28.100
libavcodec 59. 37.100 / 59. 37.100
libavformat 59. 27.100 / 59. 27.100
libavdevice 59. 7.100 / 59. 7.100
libavfilter 8. 44.100 / 8. 44.100
libswscale 6. 7.100 / 6. 7.100
libswresample 4. 7.100 / 4. 7.100
libpostproc 56. 6.100 / 56. 6.100
Guessed Channel Layout for Input Stream #0.1 : stereo
Input #0, avi, from '2012-01-03_21.46.40_6.29GB_15.avi':
Metadata:
software : Lavf59.27.100
Duration: 00:00:15.00, start: 0.000000, bitrate: 29838 kb/s
Stream #0:0: Video: dvvideo (dvsd / 0x64737664), yuv420p, 720x576 [SAR 16:15 DAR 4:3], 28877 kb/s, 25 fps, 25 tbr, 25 tbn
Stream #0:1: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 32000 Hz, stereo, s16, 1024 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (dvvideo (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (pcm_s16le (native) -> aac (native))
Press [q] to stop, [?] for help
[libx264 @ 0x56314ac35f40] using SAR=16/15
[libx264 @ 0x56314ac35f40] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.1 Cache64
[libx264 @ 0x56314ac35f40] profile High, level 3.0, 4:2:0, 8-bit
[libx264 @ 0x56314ac35f40] 264 - core 164 r3101 b093bbe - H.264/MPEG-4 AVC codec - Copyleft 2003-2022 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=3 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '2012-01-03_21.46.40_6.29GB_15.mp4':
Metadata:
software : Lavf59.27.100
encoder : Lavf59.27.100
Stream #0:0: Video: h264 (avc1 / 0x31637661), yuv420p(bottom coded first (swapped)), 720x576 [SAR 16:15 DAR 4:3], q=2-31, 25 fps, 12800 tbn
Metadata:
encoder : Lavc59.37.100 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A
Stream #0:1: Audio: aac (LC) (mp4a / 0x6134706D), 32000 Hz, stereo, fltp, 128 kb/s
Metadata:
encoder : Lavc59.37.100 aac
frame= 375 fps= 13 q=-1.0 Lsize= 7188kB time=00:00:15.00 bitrate=3923.4kbits/s speed=0.525x
video:6932kB audio:243kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.177509%
[libx264 @ 0x56314ac35f40] frame I:4 Avg QP:25.47 size: 50488
[libx264 @ 0x56314ac35f40] frame P:98 Avg QP:27.43 size: 30740
[libx264 @ 0x56314ac35f40] frame B:273 Avg QP:29.77 size: 14223
[libx264 @ 0x56314ac35f40] consecutive B-frames: 2.7% 0.5% 0.8% 96.0%
[libx264 @ 0x56314ac35f40] mb I I16..4: 1.4% 96.4% 2.3%
[libx264 @ 0x56314ac35f40] mb P I16..4: 0.5% 26.3% 2.2% P16..4: 25.0% 14.7% 7.9% 0.0% 0.0% skip:23.4%
[libx264 @ 0x56314ac35f40] mb B I16..4: 0.1% 1.9% 0.3% B16..8: 29.0% 13.2% 5.7% direct: 9.0% skip:40.8% L0:36.7% L1:35.9% BI:27.4%
[libx264 @ 0x56314ac35f40] 8x8 transform intra:90.0% inter:70.6%
[libx264 @ 0x56314ac35f40] coded y,uvDC,uvAC intra: 90.0% 83.1% 35.5% inter: 34.6% 34.4% 4.0%
[libx264 @ 0x56314ac35f40] i16 v,h,dc,p: 40% 29% 3% 28%
[libx264 @ 0x56314ac35f40] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 19% 23% 5% 4% 6% 5% 8% 10%
[libx264 @ 0x56314ac35f40] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 18% 29% 15% 5% 5% 6% 6% 7% 8%
[libx264 @ 0x56314ac35f40] i8c dc,h,v,p: 47% 15% 29% 8%
[libx264 @ 0x56314ac35f40] Weighted P-Frames: Y:27.6% UV:12.2%
[libx264 @ 0x56314ac35f40] ref P L0: 47.0% 20.2% 18.8% 10.9% 3.1%
[libx264 @ 0x56314ac35f40] ref B L0: 91.1% 6.5% 2.3%
[libx264 @ 0x56314ac35f40] ref B L1: 97.9% 2.1%
[libx264 @ 0x56314ac35f40] kb/s:3785.21
[aac @ 0x56314ac37000] Qavg: 418.857
Thanks
-Ulf
More information about the ffmpeg-user
mailing list