[FFmpeg-trac] #6868(ffmpeg:new): HLS segmenter doesn't cut properly with AVC Baseline level 3.0
FFmpeg
trac at avcodec.org
Sun Nov 26 23:57:02 EET 2017
#6868: HLS segmenter doesn't cut properly with AVC Baseline level 3.0
------------------------------------+----------------------------------
Reporter: beloko | Owner:
Type: defect | Status: new
Priority: normal | Component: ffmpeg
Version: git-master | Resolution:
Keywords: HLS | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
------------------------------------+----------------------------------
Comment (by beloko):
My FFMPEG build is now up to date.
I git last sources from : https://git.ffmpeg.org/ffmpeg.git
Compilation finished 20 minutes ago...
Unfortunately the first TS isn't cut properly.
Here is the command line and its verbose output :
{{{
C:\Users\Beloko\Desktop\FFMPEG>ffmpeg.exe -i "D:\Video Samples
\Sony_Alpha_7R_II_video-test-4K.mp4" -loglevel verbose -threads 0 -c:a
libfdk_aac -sn -vcodec libx264 -vprofile baseline -vlevel 3.0
-force_key_frames "expr:gte(t,n_forced*4)" -r 25 -f hls -hls_time 4
-hls_list_size 99999 -start_number 1 -hls_segment_type mpegts -t 10
"C:\Users\Beloko\Desktop\Sony_Alpha_7R_II_video-test-4K.m3u8"
ffmpeg version N-89257-g2779d33-Reino Copyright (c) 2000-2017 the FFmpeg
developers
built with gcc 7.1.0 (GCC)
configuration: --arch=x86_64 --target-os=mingw32 --cross-
prefix=/home/beloko/FFMpeg_Builder/sandbox/cross_compilers/mingw-w64-x86_64/bin/x86_64-w64-mingw32-
--pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino
--enable-gray --enable-version3 --disable-debug --disable-doc --disable-
htmlpages --disable-manpages --disable-podpages --disable-txtpages
--disable-w32threads --enable-fontconfig --enable-gmp --enable-gnutls
--enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca
--enable-libflite --enable-libfreetype --enable-libfribidi --enable-libgme
--enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame
--enable-libmysofa --enable-libopencore-amrnb --enable-libopencore-amrwb
--enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-
libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-
libtwolame --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx
--enable-libwebp --enable-libzimg --enable-libzvbi --extra-
cflags=-DLIBTWOLAME_STATIC --extra-cflags=-DMODPLUG_STATIC --extra-
cflags=-DCACA_STATIC --enable-gpl --enable-avisynth --enable-frei0r
--enable-filter=frei0r --enable-librubberband --enable-libvidstab
--enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid
--enable-libmfx --enable-avresample --extra-cflags='-mtune=generic'
--extra-cflags=-O3 --enable-static --disable-shared
--prefix=/home/beloko/FFMpeg_Builder/sandbox/cross_compilers/mingw-w64-x86_64/x86_64-w64-mingw32
--enable-nonfree --enable-decklink --enable-libfdk-aac
libavutil 56. 3.100 / 56. 3.100
libavcodec 58. 3.105 / 58. 3.105
libavformat 58. 2.102 / 58. 2.102
libavdevice 58. 0.100 / 58. 0.100
libavfilter 7. 5.100 / 7. 5.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 0.101 / 5. 0.101
libswresample 3. 0.101 / 3. 0.101
libpostproc 55. 0.100 / 55. 0.100
[h264 @ 0000014bc898de20] Reinit context to 3840x2160, pix_fmt: yuv420p
Guessed Channel Layout for Input Stream #0.1 : stereo
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'D:\Video Samples
\Sony_Alpha_7R_II_video-test-4K.mp4':
Metadata:
major_brand : XAVC
minor_version : 16785407
compatible_brands: XAVCiso2mp42
creation_time : 2015-06-04T10:40:51.000000Z
Duration: 00:01:34.55, start: 0.000000, bitrate: 98373 kb/s
Stream #0:0(eng): Video: h264 (High), 1 reference frame (avc1 /
0x31637661), yuv420p(tv, bt709/bt709/iec61966-2-4, left), 3840x2160 [SAR
1:1 DAR 16:9], 96631 kb/s, 23.98 fps, 23.98 tbr, 24k tbn, 47.95 tbc
(default)
Metadata:
creation_time : 2015-06-04T10:40:51.000000Z
handler_name : Video Media Handler
encoder : AVC Coding
Stream #0:1(eng): Audio: pcm_s16be (twos / 0x736F7774), 48000 Hz,
stereo, s16, 1536 kb/s (default)
Metadata:
creation_time : 2015-06-04T10:40:51.000000Z
handler_name : Sound Media Handler
Stream #0:2(eng): Data: none (rtmd / 0x646D7472), 196 kb/s (default)
Metadata:
creation_time : 2015-06-04T10:40:51.000000Z
handler_name : Timed Metadata Media Handler
timecode : 00:00:00:00
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (pcm_s16be (native) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
[h264 @ 0000014bca7581c0] Reinit context to 3840x2160, pix_fmt: yuv420p
[graph 0 input from stream 0:0 @ 0000014bd0a7a300] w:3840 h:2160
pixfmt:yuv420p tb:1/24000 fr:24000/1001 sar:1/1 sws_param:flags=2
[libx264 @ 0000014bc899c9a0] using SAR=1/1
[libx264 @ 0000014bc899c9a0] frame MB size (240x135) > level limit (1620)
[libx264 @ 0000014bc899c9a0] DPB size (1 frames, 32400 mbs) > level limit
(0 frames, 8100 mbs)
[libx264 @ 0000014bc899c9a0] MB rate (810000) > level limit (40500)
[libx264 @ 0000014bc899c9a0] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
[libx264 @ 0000014bc899c9a0] profile Constrained Baseline, level 3.0
[libx264 @ 0000014bc899c9a0] 264 - core 148 r2795M aaa9aa8 - H.264/MPEG-4
AVC codec - Copyleft 2003-2017 - http://www.videolan.org/x264.html -
options: cabac=0 ref=1 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7
psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=1
8x8dct=0 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=0 weightp=0 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
[graph_1_in_0_1 @ 0000014bd0a7ab20] tb:1/48000 samplefmt:s16
samplerate:48000 chlayout:0x3
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K1.ts' for writing
[mpegts @ 0000014bd797d1e0] muxrate VBR, pcr every 2 pkts, sdt every
2147483647, pat/pmt every 2147483647 pkts
Output #0, hls, to 'C:\Users\Beloko\Desktop\Sony_Alpha_7R_II_video-test-
4K.m3u8':
Metadata:
major_brand : XAVC
minor_version : 16785407
compatible_brands: XAVCiso2mp42
encoder : Lavf58.2.102
Stream #0:0(eng): Video: h264 (libx264), 1 reference frame,
yuv420p(progressive, left), 3840x2160 [SAR 1:1 DAR 16:9], q=-1--1, 25 fps,
90k tbn, 25 tbc (default)
Metadata:
creation_time : 2015-06-04T10:40:51.000000Z
handler_name : Video Media Handler
encoder : Lavc58.3.105 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream #0:1(eng): Audio: aac (libfdk_aac), 48000 Hz, stereo, s16,
delay 2048, 139 kb/s (default)
Metadata:
creation_time : 2015-06-04T10:40:51.000000Z
handler_name : Sound Media Handler
encoder : Lavc58.3.105 libfdk_aac
*** 1 dup!
Last message repeated 1 times
*** 1 dup!5 fps= 54 q=28.0 size=N/A time=00:00:02.41 bitrate=N/A dup=2
drop=0 speed=2.37x
*** 1 dup!9 fps= 52 q=28.0 size=N/A time=00:00:03.41 bitrate=N/A dup=3
drop=0 speed=2.23x
*** 1 dup!2 fps= 50 q=28.0 size=N/A time=00:00:03.96 bitrate=N/A dup=4
drop=0 speed=1.94x
*** 1 dup!7 fps= 50 q=28.0 size=N/A time=00:00:04.94 bitrate=N/A dup=5
drop=0 speed=1.94x
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K2.ts' for writing
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K.m3u8.tmp' for writing
[hls muxer @ 0000014bca772980] EXT-X-MEDIA-SEQUENCE:1
*** 1 dup!
*** 1 dup!0 fps= 44 q=28.0 size=N/A time=00:00:07.40 bitrate=N/A dup=7
drop=0 speed=1.81x
*** 1 dup!5 fps= 42 q=28.0 size=N/A time=00:00:07.95 bitrate=N/A dup=8
drop=0 speed=1.73x
*** 1 dup!9 fps= 30 q=28.0 size=N/A time=00:00:09.40 bitrate=N/A dup=9
drop=0 speed=1.24x
No more output streams to write to, finishing.:09.42 bitrate=N/A dup=10
drop=0 speed=1.07x
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K3.ts' for writing
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K.m3u8.tmp' for writing
[hls muxer @ 0000014bca772980] EXT-X-MEDIA-SEQUENCE:1
[hls @ 0000014bc897d5c0] Opening 'C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K.m3u8.tmp' for writing
[hls muxer @ 0000014bca772980] EXT-X-MEDIA-SEQUENCE:1
frame= 250 fps= 21 q=-1.0 Lsize=N/A time=00:00:10.00 bitrate=N/A dup=10
drop=0 speed=0.847x
video:25931kB audio:172kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
Input file #0 (D:\Video Samples\Sony_Alpha_7R_II_video-test-4K.mp4):
Input stream #0:0 (video): 250 packets read (59642071 bytes); 242 frames
decoded;
Input stream #0:1 (audio): 480 packets read (1921920 bytes); 480 frames
decoded (480480 samples);
Input stream #0:2 (data): 11 packets read (11264 bytes);
Total: 741 packets (61575255 bytes) demuxed
Output file #0 (C:\Users\Beloko\Desktop\Sony_Alpha_7R_II_video-test-
4K.m3u8):
Output stream #0:0 (video): 250 frames encoded; 250 packets muxed
(26552883 bytes);
Output stream #0:1 (audio): 469 frames encoded (480000 samples); 471
packets muxed (175841 bytes);
Total: 721 packets (26728724 bytes) muxed
[libx264 @ 0000014bc899c9a0] frame I:4 Avg QP:12.68 size:623730
[libx264 @ 0000014bc899c9a0] frame P:246 Avg QP:17.49 size: 97794
[libx264 @ 0000014bc899c9a0] mb I I16..4: 69.4% 0.0% 30.6%
[libx264 @ 0000014bc899c9a0] mb P I16..4: 1.8% 0.0% 1.5% P16..4:
16.2% 2.5% 1.4% 0.0% 0.0% skip:76.5%
[libx264 @ 0000014bc899c9a0] coded y,uvDC,uvAC intra: 40.9% 47.6% 19.1%
inter: 13.5% 15.0% 0.8%
[libx264 @ 0000014bc899c9a0] i16 v,h,dc,p: 65% 19% 10% 6%
[libx264 @ 0000014bc899c9a0] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 18% 21%
8% 7% 6% 6% 6% 7%
[libx264 @ 0000014bc899c9a0] i8c dc,h,v,p: 66% 19% 12% 3%
[libx264 @ 0000014bc899c9a0] kb/s:21241.80
C:\Users\Beloko\Desktop\FFMPEG>type "C:\Users\Beloko\Desktop
\Sony_Alpha_7R_II_video-test-4K.m3u8"
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:5
#EXT-X-MEDIA-SEQUENCE:1
#EXTINF:4.042667,
Sony_Alpha_7R_II_video-test-4K1.ts
#EXTINF:4.000000,
Sony_Alpha_7R_II_video-test-4K2.ts
#EXTINF:2.000000,
Sony_Alpha_7R_II_video-test-4K3.ts
#EXT-X-ENDLIST
}}}
I got the MP4 video source file from here :
http://4kmedia.org/sony-alpha-7r-2-uhd-4k-demo/
--
Ticket URL: <https://trac.ffmpeg.org/ticket/6868#comment:2>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list