[FFmpeg-user] Extra video frames were added when doing the resolution transform

Du Dengke pinganddu90 at gmail.com
Sat Mar 7 12:34:42 EET 2020


Thanks, add the log:

  libavutil      56. 41.100 / 56. 41.100
  libavcodec     58. 70.100 / 58. 70.100
  libavformat    58. 38.101 / 58. 38.101
  libavdevice    58.  9.103 / 58.  9.103
  libavfilter     7. 76.100 /  7. 76.100
  libswscale      5.  6.100 /  5.  6.100
  libswresample   3.  6.100 /  3.  6.100
  libpostproc    55.  6.100 / 55.  6.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'test.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf56.36.100
  Duration: 00:03:54.17, start: 0.000000, bitrate: 1619 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
1280x720, 1496 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc (default)
    Metadata:
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz,
stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
  Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
[libx264 @ 000001e1f97800c0] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 000001e1f97800c0] profile High, level 3.0, 4:2:0, 8-bit
[libx264 @ 000001e1f97800c0] 264 - core 159 - H.264/MPEG-4 AVC codec -
Copyleft 2003-2019 - 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=11 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 'test2.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.38.101
    Stream #0:0(und): Video: h264 (libx264) (avc1 / 0x31637661), yuv420p,
640x360, q=-1--1, 25 fps, 12800 tbn, 25 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      encoder         : Lavc58.70.100 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz,
stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
      encoder         : Lavc58.70.100 aac
frame= 5854 fps=209 q=-1.0 Lsize=   16404kB time=00:03:54.08 bitrate=
574.1kbits/s dup=32 drop=0 speed=8.34x
video:12507kB audio:3683kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 1.323598%
[libx264 @ 000001e1f97800c0] frame I:97    Avg QP:16.95  size: 18322
[libx264 @ 000001e1f97800c0] frame P:1661  Avg QP:22.33  size:  4457
[libx264 @ 000001e1f97800c0] frame B:4096  Avg QP:24.75  size:   885
[libx264 @ 000001e1f97800c0] consecutive B-frames:  4.9%  3.7%  5.1% 86.3%
[libx264 @ 000001e1f97800c0] mb I  I16..4: 31.0% 40.1% 28.8%
[libx264 @ 000001e1f97800c0] mb P  I16..4:  4.0%  7.2%  1.1%  P16..4: 28.4%
14.5%  8.5%  0.0%  0.0%    skip:36.2%
[libx264 @ 000001e1f97800c0] mb B  I16..4:  0.4%  0.6%  0.0%  B16..8: 28.6%
 4.7%  0.9%  direct: 1.1%  skip:63.7%  L0:42.7% L1:47.5% BI: 9.8%
[libx264 @ 000001e1f97800c0] 8x8 transform intra:53.6% inter:72.3%
[libx264 @ 000001e1f97800c0] coded y,uvDC,uvAC intra: 41.1% 56.9% 22.6%
inter: 7.8% 9.0% 0.7%
[libx264 @ 000001e1f97800c0] i16 v,h,dc,p: 32% 37% 11% 20%
[libx264 @ 000001e1f97800c0] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 29% 22% 25%  3%
 4%  4%  4%  4%  4%
[libx264 @ 000001e1f97800c0] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 28% 27% 11%  5%
 6%  7%  6%  5%  5%
[libx264 @ 000001e1f97800c0] i8c dc,h,v,p: 54% 23% 18%  4%
[libx264 @ 000001e1f97800c0] Weighted P-Frames: Y:4.6% UV:3.3%
[libx264 @ 000001e1f97800c0] ref P L0: 67.2% 13.8% 14.0%  4.9%  0.0%
[libx264 @ 000001e1f97800c0] ref B L0: 91.1%  7.2%  1.7%
[libx264 @ 000001e1f97800c0] ref B L1: 96.8%  3.2%
[libx264 @ 000001e1f97800c0] kb/s:437.54
[aac @ 000001e1f94ab600] Qavg: 175.001

On Sat, Mar 7, 2020 at 6:21 PM Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:

> Am Sa., 7. März 2020 um 11:16 Uhr schrieb Du Dengke <pinganddu90 at gmail.com
> >:
>
> > When I run the following command
> >     ffmpeg -i test.mp4 -vf scale=640x360 test2.mp4
>
> Complete, uncut console output missing.
>
> > 32 frames was added after the transform, and I saw some static picture
> > within the first second.
> > My question:
> >     Why the 32 frames was added, does this video trigger some mechanism?
> > And why the static picture was added at the first?
>
> See above, most likely because audio and video have different
> start times which FFmpeg's muxer does not support.
>
> Carl Eugen
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".


More information about the ffmpeg-user mailing list