[FFmpeg-trac] #2846(undetermined:new): Two-pass libx264 -preset veryslow crashes on some MPEG-type inputs

FFmpeg trac at avcodec.org
Fri Aug 23 16:14:26 CEST 2013


#2846: Two-pass libx264 -preset veryslow crashes on some MPEG-type inputs
-------------------------------------+-------------------------------------
             Reporter:               |                    Owner:
  francois.visagie@…                 |                   Status:  new
                 Type:  defect       |                Component:
             Priority:  normal       |  undetermined
              Version:  unspecified  |               Resolution:
             Keywords:  crash        |               Blocked By:
  libx264                            |  Reproduced by developer:  0
             Blocking:               |
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------

Comment (by francois.visagie@…):

 Replying to [comment:16 cehoyos]:
 > Replying to [comment:15 francois.visagie@…]:
 > > the fact remains that at least '-c:v libx264 -preset ultrafast'
 handles this particular scenario correctly
 >
 > (I don't think so, I actually believe that it behaves much worse than
 -preset veryslow.)
 > Please provide command lines and complete, uncut console output.

 Here you go:

 C:\Users\fvisagie\Videos\Home Videos\Testing\Bug information>ffmpeg -y -i
 ticket_2846_crash_libx264.vob -an -c:v libx264 -preset ultrafast
 -fastfirstpass 1 -f r
 awvideo -b:v 1000000 -pass 1 NUL
 ffmpeg version N-55159-gf118b41 Copyright (c) 2000-2013 the FFmpeg
 developers
   built on Aug  1 2013 18:01:57 with gcc 4.7.3 (GCC)
   configuration: --enable-gpl --enable-version3 --disable-w32threads
 --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r
 --enable-gnutls --enab
 le-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-
 libfreetype --enable-libgsm --enable-libilbc --enable-libmodplug --enable-
 libmp3lame --ena
 ble-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
 --enable-libopus --enable-librtmp --enable-libschroedinger --enable-
 libsoxr --enable-libsp
 eex --enable-libtheora --enable-libtwolame --enable-libvo-aacenc --enable-
 libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264
 --enable-libxavs --
 enable-libxvid --enable-zlib
   libavutil      52. 40.100 / 52. 40.100
   libavcodec     55. 19.100 / 55. 19.100
   libavformat    55. 12.102 / 55. 12.102
   libavdevice    55.  3.100 / 55.  3.100
   libavfilter     3. 82.100 /  3. 82.100
   libswscale      2.  4.100 /  2.  4.100
   libswresample   0. 17.103 /  0. 17.103
   libpostproc    52.  3.100 / 52.  3.100
 [mpeg2video @ 03b0e220] Invalid frame dimensions 0x0.
 Input #0, mpeg, from 'ticket_2846_crash_libx264.vob':
   Duration: 00:02:11.08, start: 4199.857333, bitrate: 7838 kb/s
     Stream #0:0[0x8a]: Audio: dts (DTS), 48000 Hz, 5.1(side), fltp, 1536
 kb/s
     Stream #0:1[0x80]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:2[0x1e0]: Video: mpeg2video (Main), yuv420p, 720x480 [SAR
 32:27 DAR 16:9], max. 6000 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
     Stream #0:3[0x1bf]: Data: dvd_nav_packet
 [libx264 @ 04181020] using SAR=32/27
 [libx264 @ 04181020] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
 AVX
 [libx264 @ 04181020] profile Constrained Baseline, level 3.0
 Output #0, rawvideo, to 'NUL':
   Metadata:
     encoder         : Lavf55.12.102
     Stream #0:0: Video: h264 (libx264), yuv420p, 720x480 [SAR 32:27 DAR
 16:9], q=-1--1, pass 1, 1000 kb/s, 90k tbn, 29.97 tbc
 Stream mapping:
   Stream #0:2 -> #0:0 (mpeg2video -> libx264)
 Press [q] to stop, [?] for help
 [mpeg2video @ 03b0e220] warning: first frame is no keyframe
     Last message repeated 1 times
 frame= 3924 fps=526 q=-1.0 Lsize=   15960kB time=00:02:10.93 bitrate=
 998.6kbits/s dup=0 drop=1
 video:15960kB audio:0kB subtitle:0 global headers:0kB muxing overhead
 0.000000%
 [libx264 @ 04181020] frame I:16    Avg QP:32.12  size: 11993
 [libx264 @ 04181020] frame P:3908  Avg QP:35.22  size:  4133
 [libx264 @ 04181020] mb I  I16..4: 100.0%  0.0%  0.0%
 [libx264 @ 04181020] mb P  I16..4: 21.4%  0.0%  0.0%  P16..4: 40.3%  0.0%
 0.0%  0.0%  0.0%    skip:38.2%
 [libx264 @ 04181020] final ratefactor: 31.59
 [libx264 @ 04181020] coded y,uvDC,uvAC intra: 18.0% 23.2% 1.9% inter:
 15.1% 15.1% 0.3%
 [libx264 @ 04181020] i16 v,h,dc,p: 34% 33% 18% 15%
 [libx264 @ 04181020] i8c dc,h,v,p: 56% 21% 16%  7%
 [libx264 @ 04181020] kb/s:998.56

 C:\Users\fvisagie\Videos\Home Videos\Testing\Bug information>ffmpeg -y -i
 ticket_2846_crash_libx264.vob -filter:a  aformat=channel_layouts=stereo
 -c:v libx264 -
 preset ultrafast -b:v 1000000 -pass 2 zzz.mp4
 ffmpeg version N-55159-gf118b41 Copyright (c) 2000-2013 the FFmpeg
 developers
   built on Aug  1 2013 18:01:57 with gcc 4.7.3 (GCC)
   configuration: --enable-gpl --enable-version3 --disable-w32threads
 --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r
 --enable-gnutls --enab
 le-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-
 libfreetype --enable-libgsm --enable-libilbc --enable-libmodplug --enable-
 libmp3lame --ena
 ble-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
 --enable-libopus --enable-librtmp --enable-libschroedinger --enable-
 libsoxr --enable-libsp
 eex --enable-libtheora --enable-libtwolame --enable-libvo-aacenc --enable-
 libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264
 --enable-libxavs --
 enable-libxvid --enable-zlib
   libavutil      52. 40.100 / 52. 40.100
   libavcodec     55. 19.100 / 55. 19.100
   libavformat    55. 12.102 / 55. 12.102
   libavdevice    55.  3.100 / 55.  3.100
   libavfilter     3. 82.100 /  3. 82.100
   libswscale      2.  4.100 /  2.  4.100
   libswresample   0. 17.103 /  0. 17.103
   libpostproc    52.  3.100 / 52.  3.100
 [mpeg2video @ 03226f60] Invalid frame dimensions 0x0.
 Input #0, mpeg, from 'ticket_2846_crash_libx264.vob':
   Duration: 00:02:11.08, start: 4199.857333, bitrate: 7838 kb/s
     Stream #0:0[0x8a]: Audio: dts (DTS), 48000 Hz, 5.1(side), fltp, 1536
 kb/s
     Stream #0:1[0x80]: Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:2[0x1e0]: Video: mpeg2video (Main), yuv420p, 720x480 [SAR
 32:27 DAR 16:9], max. 6000 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
     Stream #0:3[0x1bf]: Data: dvd_nav_packet
 [libx264 @ 0447f020] using SAR=32/27
 [libx264 @ 0447f020] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
 AVX
 [libx264 @ 0447f020] profile Constrained Baseline, level 3.0
 [libx264 @ 0447f020] 264 - core 135 r2345 f0c1c53 - H.264/MPEG-4 AVC codec
 - Copyleft 2003-2013 - http://www.videolan.org/x264.html - options:
 cabac=0 ref=1 deb
 lock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0
 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11
 fast_pskip=1 chroma_qp_
 offset=0 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1
 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0
 keyint=250 keyint_m
 in=25 scenecut=0 intra_refresh=0 rc=2pass mbtree=0 bitrate=1000
 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 cplxblur=20.0 qblur=0.5
 ip_ratio=1.40 aq=0
 Output #0, mp4, to 'zzz.mp4':
   Metadata:
     encoder         : Lavf55.12.102
     Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p,
 720x480 [SAR 32:27 DAR 16:9], q=-1--1, pass 2, 1000 kb/s, 30k tbn, 29.97
 tbc
     Stream #0:1: Audio: aac (libvo_aacenc) ([64][0][0][0] / 0x0040), 48000
 Hz, stereo, s16, 128 kb/s
 Stream mapping:
   Stream #0:2 -> #0:0 (mpeg2video -> libx264)
   Stream #0:0 -> #0:1 (dca -> libvo_aacenc)
 Press [q] to stop, [?] for help
 [mpeg2video @ 03226f60] warning: first frame is no keyframe
     Last message repeated 1 times
 [libx264 @ 0447f020] 2nd pass has more frames than 1st pass
 (3924)e=1126.9kbits/s dup=4 drop=0
 [libx264 @ 0447f020] continuing anyway, at constant QP=36
 frame= 3929 fps=408 q=-1.0 Lsize=   18182kB time=00:02:11.10
 bitrate=1136.1kbits/s dup=4 drop=0
 video:16021kB audio:2049kB subtitle:0 global headers:0kB muxing overhead
 0.617050%
 [libx264 @ 0447f020] frame I:16    Avg QP:32.50  size: 11913
 [libx264 @ 0447f020] frame P:3913  Avg QP:35.27  size:  4144
 [libx264 @ 0447f020] mb I  I16..4: 100.0%  0.0%  0.0%
 [libx264 @ 0447f020] mb P  I16..4: 22.5%  0.0%  0.0%  P16..4: 39.0%  0.0%
 0.0%  0.0%  0.0%    skip:38.5%
 [libx264 @ 0447f020] coded y,uvDC,uvAC intra: 19.0% 23.7% 1.7% inter:
 15.0% 14.6% 0.2%
 [libx264 @ 0447f020] i16 v,h,dc,p: 34% 33% 18% 15%
 [libx264 @ 0447f020] i8c dc,h,v,p: 55% 22% 16%  8%
 [libx264 @ 0447f020] kb/s:1001.10

 C:\Users\fvisagie\Videos\Home Videos\Testing\Bug information>

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/2846#comment:17>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list