不知怎的,我发布了Azure Media Services,除了这些设置有大量的帧丢失(几乎每一帧):
ffmpeg -i "http://stream01/hls/live/playlist-mid.m3u8" -strict -2 -c:a aac -b:a 192k
-ar 44100 -r 25 -g 60 -keyint_min 60 -b:v 2000k -c:v libx264 -bufsize 2000k
-maxrate 2000k -f flv "rtmp://publishurl.working.is/mystream1"
+我无法播放Azure中的网址。
当我发布到本地nginx-rtmp服务器时,帧丢失仍然存在,尽管我可以播放它。所以,我认为帧丢弃与ffmpeg无关,而不是Azure。处理器没有过载,可用带宽非常好。
当我尝试URL的original
设置(位于最底部)时,我会另外发现这个ffmpeg错误Past duration 0.719994 too large
此处还有输出内容:
c:\ffmpeg\bin>ffmpeg -i "http://stream01/hls/live/playlist-mid.m3u8" -strict -2 -c:a aac -b:a 192k -ar 44100 -r 25 -g 60 -keyint_min 60 -b:v 2000k -c:
v libx264 -bufsize 1000k -maxrate 2000k -f flv "rtmp://********.channel.mediaservices.windows.net:1935/live/9590f0be/mystream1"
ffmpeg version N-69972-g6c91afe Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.2 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnu
tls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-
libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-l
ibrtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --
enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --ena
ble-libxvid --enable-lzma --enable-decklink --enable-zlib
libavutil 54. 19.100 / 54. 19.100
libavcodec 56. 25.100 / 56. 25.100
libavformat 56. 23.100 / 56. 23.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 11.100 / 5. 11.100
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, hls,applehttp, from 'http://stream01/hls/live/playlist-mid.m3u8':
Duration: N/A, start: 3314.605633, bitrate: N/A
Program 0
Metadata:
variant_bitrate : 1500000
Stream #0:0: Video: h264 (Main) ([27][0][0][0] / 0x001B), yuv420p(tv), 854x480 [SAR 1:1 DAR 427:240], 50 fps, 50 tbr, 90k tbn, 100 tbc
Metadata:
variant_bitrate : 1500000
Stream #0:1: Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, stereo, fltp, 216 kb/s
Metadata:
variant_bitrate : 1500000
[libx264 @ 0000000000306280] using SAR=1/1
[libx264 @ 0000000000306280] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
[libx264 @ 0000000000306280] profile High, level 3.0
[libx264 @ 0000000000306280] 264 - core 144 r2525 40bb568 - 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 dead
zone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_in
tra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=60 keyint_min=31 scenecut=40 intra_refresh=0 rc_lookahea
d=40 rc=cbr mbtree=1 bitrate=2000 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 vbv_maxrate=2000 vbv_bufsize=1000 nal_hrd=none filler=0 ip_ratio=1.
40 aq=1:1.00
Output #0, flv, to 'rtmp://*******.channel.mediaservices.windows.net:1935/live/37b4e25/mystream1':
Metadata:
encoder : Lavf56.23.100
Stream #0:0: Video: h264 (libx264) ([7][0][0][0] / 0x0007), yuv420p, 854x480 [SAR 1:1 DAR 427:240], q=-1--1, 2000 kb/s, 25 fps, 1k tbn, 25 tbc
Metadata:
variant_bitrate : 1500000
encoder : Lavc56.25.100 libx264
Stream #0:1: Audio: aac ([10][0][0][0] / 0x000A), 44100 Hz, stereo, fltp, 192 kb/s
Metadata:
variant_bitrate : 1500000
encoder : Lavc56.25.100 aac
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
[flv @ 0000000000305820] Failed to update header with correct duration.1.4kbits/s dup=0 drop=10697
[flv @ 0000000000305820] Failed to update header with correct filesize.
frame=10714 fps= 24 q=-1.0 Lsize= 100583kB time=00:07:11.08 bitrate=1911.4kbits/s dup=0 drop=10701
video:90024kB audio:10042kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.516478%
[libx264 @ 0000000000306280] frame I:190 Avg QP:10.58 size: 72438
[libx264 @ 0000000000306280] frame P:3406 Avg QP:14.32 size: 19296
[libx264 @ 0000000000306280] frame B:7118 Avg QP:19.55 size: 1784
[libx264 @ 0000000000306280] consecutive B-frames: 8.8% 4.4% 10.5% 76.3%
[libx264 @ 0000000000306280] mb I I16..4: 23.0% 20.2% 56.8%
[libx264 @ 0000000000306280] mb P I16..4: 2.7% 4.5% 5.2% P16..4: 41.9% 11.6% 8.7% 0.0% 0.0% skip:25.4%
[libx264 @ 0000000000306280] mb B I16..4: 0.1% 0.1% 0.2% B16..8: 26.5% 2.2% 0.5% direct: 3.2% skip:67.1% L0:51.0% L1:38.2% BI:10.8%
[libx264 @ 0000000000306280] 8x8 transform intra:31.3% inter:36.6%
[libx264 @ 0000000000306280] coded y,uvDC,uvAC intra: 80.5% 73.5% 51.1% inter: 16.1% 18.8% 5.8%
[libx264 @ 0000000000306280] i16 v,h,dc,p: 21% 29% 27% 23%
[libx264 @ 0000000000306280] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 32% 19% 4% 4% 4% 5% 4% 7%
[libx264 @ 0000000000306280] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 27% 30% 15% 4% 5% 5% 5% 4% 5%
[libx264 @ 0000000000306280] i8c dc,h,v,p: 38% 30% 24% 8%
[libx264 @ 0000000000306280] Weighted P-Frames: Y:1.8% UV:0.4%
[libx264 @ 0000000000306280] ref P L0: 78.0% 8.5% 10.1% 3.3% 0.0%
[libx264 @ 0000000000306280] ref B L0: 91.3% 7.9% 0.8%
[libx264 @ 0000000000306280] ref B L1: 95.4% 4.6%
[libx264 @ 0000000000306280] kb/s:1716.97
Received signal 2: terminating.