[FFmpeg-trac] #4298(avfilter:open): zoompan filter creates shaky image
FFmpeg
trac at avcodec.org
Sat Feb 7 09:47:57 CET 2015
#4298: zoompan filter creates shaky image
------------------------------------+------------------------------------
Reporter: slhck | Owner:
Type: defect | Status: open
Priority: normal | Component: avfilter
Version: git-master | Resolution:
Keywords: zoompan | Blocked By:
Blocking: | Reproduced by developer: 1
Analyzed by developer: 0 |
------------------------------------+------------------------------------
Comment (by slhck):
A similar thing happens with video – the output is shaky and lots of
frames are dropped. (Could only test on recent stable though.)
{{{
ffmpeg -i test.mp4 -vf "zoompan=z='min(zoom+0.0015,1.5)':d=125:s=hd720"
out.mp4
ffmpeg version 2.5.3 Copyright (c) 2000-2015 the FFmpeg developers
built on Jan 18 2015 18:53:04 with Apple LLVM version 6.0
(clang-600.0.56) (based on LLVM 3.5svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/2.5.3 --enable-shared
--enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables
--enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-
libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid
--enable-libfontconfig --enable-libfreetype --enable-libtheora --enable-
libvorbis --enable-libvpx --enable-librtmp --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libfaac --enable-libass --enable-
ffplay --enable-libspeex --enable-libschroedinger --enable-libfdk-aac
--enable-openssl --enable-libopus --enable-frei0r --enable-libcaca
--enable-libsoxr --enable-libquvi --enable-libvidstab --enable-libx265
--enable-libopenjpeg --disable-decoder=jpeg2000 --extra-
cflags='-I/usr/local/Cellar/openjpeg/1.5.1_1/include/openjpeg-1.5 '
--enable-nonfree --enable-vda
libavutil 54. 15.100 / 54. 15.100
libavcodec 56. 13.100 / 56. 13.100
libavformat 56. 15.102 / 56. 15.102
libavdevice 56. 3.100 / 56. 3.100
libavfilter 5. 2.103 / 5. 2.103
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'test.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.15.102
Duration: 00:00:20.48, start: 0.315375, bitrate: 3854 kb/s
Chapter #0:0: start 0.000000, end 20.000000
Metadata:
title : Opening Credits
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
1920x1036 [SAR 1:1 DAR 480:259], 3851 kb/s, 23.98 fps, 23.98 tbr, 24k tbn,
47.95 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(eng): Subtitle: mov_text (text / 0x74786574), 0 kb/s
Metadata:
handler_name : SubtitleHandler
[libx264 @ 0x7ff5bb001800] using SAR=1/1
[libx264 @ 0x7ff5bb001800] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX
[libx264 @ 0x7ff5bb001800] profile High, level 3.1
[libx264 @ 0x7ff5bb001800] 264 - core 142 r2479 dd79a61 - H.264/MPEG-4 AVC
codec - Copyleft 2003-2014 - 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=12
lookahead_threads=2 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=23
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 'out.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.15.102
Chapter #0:0: start 0.315000, end 20.315000
Metadata:
title : Opening Credits
Stream #0:0(und): Video: h264 (libx264) ([33][0][0][0] / 0x0021),
yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=-1--1, 23.98 fps, 24k tbn, 23.98
tbc (default)
Metadata:
handler_name : VideoHandler
encoder : Lavc56.13.100 libx264
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[output stream 0:0 @ 0x7ff5ba600820] 100 buffers queued in output stream
0:0, something may be wrong.
frame= 215 fps=1.8 q=-1.0 Lsize= 1555kB time=00:00:08.88
bitrate=1434.1kbits/s dup=0 drop=23410
video:1552kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB
muxing overhead: 0.205884%
[libx264 @ 0x7fbf0b008600] frame I:3 Avg QP:18.52 size: 58670
[libx264 @ 0x7fbf0b008600] frame P:151 Avg QP:21.21 size: 8615
[libx264 @ 0x7fbf0b008600] frame B:61 Avg QP:22.90 size: 1830
[libx264 @ 0x7fbf0b008600] consecutive B-frames: 56.3% 17.7% 0.0% 26.0%
[libx264 @ 0x7fbf0b008600] mb I I16..4: 6.3% 65.8% 27.9%
[libx264 @ 0x7fbf0b008600] mb P I16..4: 2.4% 13.7% 1.7% P16..4: 22.2%
4.8% 2.7% 0.0% 0.0% skip:52.4%
[libx264 @ 0x7fbf0b008600] mb B I16..4: 0.0% 0.1% 0.0% B16..8: 48.4%
0.6% 0.0% direct: 0.1% skip:50.7% L0:43.6% L1:56.2% BI: 0.2%
[libx264 @ 0x7fbf0b008600] 8x8 transform intra:75.8% inter:85.4%
[libx264 @ 0x7fbf0b008600] coded y,uvDC,uvAC intra: 49.8% 42.4% 12.5%
inter: 8.2% 7.6% 0.1%
[libx264 @ 0x7fbf0b008600] i16 v,h,dc,p: 29% 17% 10% 44%
[libx264 @ 0x7fbf0b008600] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 20% 13% 22% 8%
7% 9% 6% 9% 5%
[libx264 @ 0x7fbf0b008600] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 13% 18% 7%
8% 8% 6% 7% 3%
[libx264 @ 0x7fbf0b008600] i8c dc,h,v,p: 65% 14% 19% 2%
[libx264 @ 0x7fbf0b008600] Weighted P-Frames: Y:2.6% UV:0.0%
[libx264 @ 0x7fbf0b008600] ref P L0: 60.9% 10.7% 14.2% 14.1% 0.1%
[libx264 @ 0x7fbf0b008600] ref B L0: 88.8% 9.4% 1.8%
[libx264 @ 0x7fbf0b008600] ref B L1: 95.5% 4.5%
[libx264 @ 0x7fbf0b008600] kb/s:1417.20
}}}
Inserting the scale filter before (as Carl-Eugen suggested) with video
magically makes the output 720p, without me requesting that.
{{{
ffmpeg -i test.mp4 -vf "scale=640:360,
zoompan=z='min(zoom+0.0015,1.5)':d=125" out.mp4
ffmpeg version 2.5.3 Copyright (c) 2000-2015 the FFmpeg developers
built on Jan 18 2015 18:53:04 with Apple LLVM version 6.0
(clang-600.0.56) (based on LLVM 3.5svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/2.5.3 --enable-shared
--enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables
--enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-
libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid
--enable-libfontconfig --enable-libfreetype --enable-libtheora --enable-
libvorbis --enable-libvpx --enable-librtmp --enable-libopencore-amrnb
--enable-libopencore-amrwb --enable-libfaac --enable-libass --enable-
ffplay --enable-libspeex --enable-libschroedinger --enable-libfdk-aac
--enable-openssl --enable-libopus --enable-frei0r --enable-libcaca
--enable-libsoxr --enable-libquvi --enable-libvidstab --enable-libx265
--enable-libopenjpeg --disable-decoder=jpeg2000 --extra-
cflags='-I/usr/local/Cellar/openjpeg/1.5.1_1/include/openjpeg-1.5 '
--enable-nonfree --enable-vda
libavutil 54. 15.100 / 54. 15.100
libavcodec 56. 13.100 / 56. 13.100
libavformat 56. 15.102 / 56. 15.102
libavdevice 56. 3.100 / 56. 3.100
libavfilter 5. 2.103 / 5. 2.103
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'test.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.15.102
Duration: 00:00:20.48, start: 0.315375, bitrate: 3854 kb/s
Chapter #0:0: start 0.000000, end 20.000000
Metadata:
title : Opening Credits
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
1920x1036 [SAR 1:1 DAR 480:259], 3851 kb/s, 23.98 fps, 23.98 tbr, 24k tbn,
47.95 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(eng): Subtitle: mov_text (text / 0x74786574), 0 kb/s
Metadata:
handler_name : SubtitleHandler
File 'out.mp4' already exists. Overwrite ? [y/N] y
[libx264 @ 0x7fb5d182fe00] using SAR=270/259
[libx264 @ 0x7fb5d182fe00] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX
[libx264 @ 0x7fb5d182fe00] profile High, level 3.1
[libx264 @ 0x7fb5d182fe00] 264 - core 142 r2479 dd79a61 - H.264/MPEG-4 AVC
codec - Copyleft 2003-2014 - 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=12
lookahead_threads=2 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=23
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 'out.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.15.102
Chapter #0:0: start 0.315000, end 20.315000
Metadata:
title : Opening Credits
Stream #0:0(und): Video: h264 (libx264) ([33][0][0][0] / 0x0021),
yuv420p, 1280x720 [SAR 270:259 DAR 480:259], q=-1--1, 23.98 fps, 24k tbn,
23.98 tbc (default)
Metadata:
handler_name : VideoHandler
encoder : Lavc56.13.100 libx264
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[output stream 0:0 @ 0x7fb5d0e01140] 100 buffers queued in output stream
0:0, something may be wrong
...
}}}
When I use `ffplay` it shows everything correctly though.
--
Ticket URL: <https://trac.ffmpeg.org/ticket/4298#comment:4>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list