Re: [FFmpeg-user] h264 mkvs fail on TV/gigablue after conversion
Moritz Barsnick wrote > This is it. Your working input video is profile High, level 4.1. ffmpeg > is choosing profile High, level 5.1.[*] It is a choice implied by the > "veryslow" preset, but you can override it specifically by adding > "-profile high -level 4.1" > (or whatever your hardware player at max supports) to your ffmpeg > command line, while keeping the preset. > > This is my best guess... Something worth trying. And that was the solution indeed! Reconverting the non-working movies with "-profile high -level 4.1" makes them play on the TV/Gigablue box. Thank you very very much :-) -- Dipl.-Inform. Frank Steiner Web: http://www.bio.ifi.lmu.de/~steiner/ Lehrstuhl f. BioinformatikMail: http://www.bio.ifi.lmu.de/~steiner/m/ LMU, Amalienstr. 17 Phone: +49 89 2180-4049 80333 Muenchen, Germany Fax: +49 89 2180-99-4049 * Rekursion kann man erst verstehen, wenn man Rekursion verstanden hat. * ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] h264 mkvs fail on TV/gigablue after conversion
On Mon, Jul 24, 2017 at 10:29:18 +0200, Frank Steiner wrote: > Do you have any idea what could go wrong here? What I could change in > converting to avoid that little "whatever" that disturbs the > (obviously older) codecs on my TV and the Gigablye box? What kind of > problem could cause the video stream to freeze? TVs and hardware decoders often have a limited set of codec features which they can decode. Back in the days of XviD, it was a bit of a matter of luck of getting them to work. In these modern days, profiles and levels describe the capabilities and features. > ffmpeg -i test_works.mkv -c:v libx264 -preset veryslow -crf 20 -tune filme > -c:a copy -c:s copy test_fails.mkv [...] > Stream #0:0(eng): Video: h264 (High), yuv420p(progressive), 1920x1044, > SAR 1:1 DAR 160:87, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (There's something here ffmpeg doesn't tell us here by default. I used mediainfo to tell, but ffprobe -show_streams also works.) > [libx264 @ 0x12cdca0] profile High, level 5.1 This is it. Your working input video is profile High, level 4.1. ffmpeg is choosing profile High, level 5.1.[*] It is a choice implied by the "veryslow" preset, but you can override it specifically by adding "-profile high -level 4.1" (or whatever your hardware player at max supports) to your ffmpeg command line, while keeping the preset. This is my best guess... Something worth trying. [*] Technical jibber: Most notably, the number of reference frames (4 vs. 16) and the number of B-frames (5 vs. 8) is different. Those things matter to a HW decoder, IIUC. Cheers, Moritz > [libx264 @ 0x12cdca0] 264 - core 148 - H.264/MPEG-4 AVC codec - Copyleft > 2003-2016 - http://www.videolan.org/x264.html - options: cabac=1 ref=16 > deblock=1:-1:-1 analyse=0x3:0x133 me=umh subme=10 psy=1 psy_rd=1.00:0.15 > mixed_ref=1 me_range=24 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 > fast_pskip=1 chroma_qp_offset=-3 threads=12 lookahead_threads=2 > sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 > constrained_intra=0 bframes=8 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 > weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=23 scenecut=40 > intra_refresh=0 rc_lookahead=60 rc=crf mbtree=1 crf=20.0 qcomp=0.60 qpmin=0 > qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00 > Output #0, matroska, to 'test_fails.mkv': > Metadata: > encoder : Lavf57.56.101 > Chapter #0:0: start 0.00, end 123.54 > Metadata: > title : 00:00:00.000 > Chapter #0:1: start 123.54, end 264.139000 > Metadata: > title : 00:02:03.540 > Chapter #0:2: start 264.139000, end 437.312000 > Metadata: > title : 00:04:24.139 > Chapter #0:3: start 437.312000, end 650.984000 > Metadata: > title : 00:07:17.312 > Chapter #0:4: start 650.984000, end 814.397000 > Metadata: > title : 00:10:50.984 > Chapter #0:5: start 814.397000, end 952.827000 > Metadata: > title : 00:13:34.397 > Chapter #0:6: start 952.827000, end 1144.894000 > Metadata: > title : 00:15:52.827 > Chapter #0:7: start 1144.894000, end 1362.611000 > Metadata: > title : 00:19:04.894 > Chapter #0:8: start 1362.611000, end 1484.191000 > Metadata: > title : 00:22:42.611 > Chapter #0:9: start 1484.191000, end 1604.394000 > Metadata: > title : 00:24:44.191 > Chapter #0:10: start 1604.394000, end 1764.513000 > Metadata: > title : 00:26:44.394 > Chapter #0:11: start 1764.513000, end 1983.773000 > Metadata: > title : 00:29:24.513 > Chapter #0:12: start 1983.773000, end 2098.346000 > Metadata: > title : 00:33:03.773 > Chapter #0:13: start 2098.346000, end 2196.444000 > Metadata: > title : 00:34:58.346 > Chapter #0:14: start 2196.444000, end 2463.336000 > Metadata: > title : 00:36:36.444 > Chapter #0:15: start 2463.336000, end 2755.044000 > Metadata: > title : 00:41:03.336 > Chapter #0:16: start 2755.044000, end 2993.199000 > Metadata: > title : 00:45:55.044 > Chapter #0:17: start 2993.199000, end 3222.344000 > Metadata: > title : 00:49:53.199 > Chapter #0:18: start 3222.344000, end 3549.004000 > Metadata: > title : 00:53:42.344 > Chapter #0:19: start 3549.004000, end 3662.993000 > Metadata: > title : 00:59:09.004 > Chapter #0:20: start 3662.993000, end 3879.876000 > Metadata: > title : 01:01:02.993 > Chapter #0:21: start 3879.876000, end 4014.761000 > Metadata: > title : 01:04:39.876 > Chapter #0:22: start 4014.761000, end 4344.632000 > Metadata: > title : 01:06:54.761 > Chapter #0:23: start 4344.632000, end 4572.902000 > Metadat
[FFmpeg-user] h264 mkvs fail on TV/gigablue after conversion
Hi, I just realized that all movies that I converted down to 720p using h264 codec don't play neither on my TV nor my Gigablue Quad box, but work fine with mplayer/mpv/xine on my Linux system. On the TV/gigablue the video stream freezes after 2-3 seconds while the audio continues to play. It doesn't matter what kind of input codec I have. I could track the problem down to a small test video. The input file is in h264 format already, and after converting the "ffmpeg -i" output looks absolutely the same, apart from the bitrate. So the TV/Gigablue are able to play h264 streams, but when I convert it with ffmpeg sth. must be changed that I can't figure out (and so don't know how to avoid it). Below is the output of the conversion command. The two files can be downloaded from https://www.bio.ifi.lmu.de/~steiner/test_works.mkv (18 MB) and https://www.bio.ifi.lmu.de/~steiner/test_fails.mkv (8.9MB) in case you want to take a look at them. Do you have any idea what could go wrong here? What I could change in converting to avoid that little "whatever" that disturbs the (obviously older) codecs on my TV and the Gigablye box? What kind of problem could cause the video stream to freeze? cu, Frank ffmpeg -i test_works.mkv -c:v libx264 -preset veryslow -crf 20 -tune filme -c:a copy -c:s copy test_fails.mkv ffmpeg version 3.2.6 Copyright (c) 2000-2017 the FFmpeg developers built with gcc 4.8 (SUSE Linux) configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64 --incdir=/usr/include/ffmpeg --extra-cflags='-fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g' --optflags='-fmessage-length=0 -grecord-gcc-switches -fstack-protector -O2 -Wall -D_FORTIFY_SOURCE=2 -funwind-tables -fasynchronous-unwind-tables -g' --disable-htmlpages --enable-pic --disable-stripping --enable-shared --disable-static --enable-gpl --disable-openssl --enable-avresample --enable-libcdio --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libcelt --enable-libcdio --enable-libdc1394 --enable-libfreetype --enable-libgsm --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-netcdf --enable-vaapi --enable-vdpau --enable-libfdk_aac --enable-nonfree --enable-libmp3lame --enable-libtwolame --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab libavutil 55. 34.101 / 55. 34.101 libavcodec 57. 64.101 / 57. 64.101 libavformat57. 56.101 / 57. 56.101 libavdevice57. 1.100 / 57. 1.100 libavfilter 6. 65.100 / 6. 65.100 libavresample 3. 1. 0 / 3. 1. 0 libswscale 4. 2.100 / 4. 2.100 libswresample 2. 3.100 / 2. 3.100 libpostproc54. 1.100 / 54. 1.100 Input #0, matroska,webm, from 'test_works.mkv': Metadata: ENCODER : Lavf57.56.101 Duration: 00:00:15.19, start: 0.00, bitrate: 9400 kb/s Chapter #0:0: start 0.00, end 123.54 Metadata: title : 00:00:00.000 Chapter #0:1: start 123.54, end 264.139000 Metadata: title : 00:02:03.540 Chapter #0:2: start 264.139000, end 437.312000 Metadata: title : 00:04:24.139 Chapter #0:3: start 437.312000, end 650.984000 Metadata: title : 00:07:17.312 Chapter #0:4: start 650.984000, end 814.397000 Metadata: title : 00:10:50.984 Chapter #0:5: start 814.397000, end 952.827000 Metadata: title : 00:13:34.397 Chapter #0:6: start 952.827000, end 1144.894000 Metadata: title : 00:15:52.827 Chapter #0:7: start 1144.894000, end 1362.611000 Metadata: title : 00:19:04.894 Chapter #0:8: start 1362.611000, end 1484.191000 Metadata: title : 00:22:42.611 Chapter #0:9: start 1484.191000, end 1604.394000 Metadata: title : 00:24:44.191 Chapter #0:10: start 1604.394000, end 1764.513000 Metadata: title : 00:26:44.394 Chapter #0:11: start 1764.513000, end 1983.773000 Metadata: title : 00:29:24.513 Chapter #0:12: start 1983.773000, end 2098.346000 Metadata: title : 00:33:03.773 Chapter #0:13: start 2098.346000, end 2196.444000 Metadata: title : 00:34:58.346 Chapter #0:14: start 2196.444000, end 2463.336000 Metadata: title : 00:36:36.444 Chapter #0:15: start 2463.336000, end 2755.044000 Metadata: title : 00:41:03.336 Chapter #0:16: start 2755.044000, end 2993.199000 Metadata: title : 00:45:55.044 Chapter #0:17: start 2993.199000, end 3222.344000 Metadata: title : 00:49:53.199 Chapter #0:18: start 3222.344000, end 3549.004000 Metadata: titl