我正在使用ffmpeg和dash.js直播视频 these instructions.除了视频以太高的帧速率播放外,它的效果很好。清单中未指定帧速率。 创建块:
SET VP9_LIVE_PARAMS=-speed 6 -threads 8 -static-thresh 0 -max-intra-rate 300 -deadline realtime -lag-in-frames 0 -error-resilient 1
ffmpeg -re -r 25 -i tcp://localhost:8891 ^
-map 0:0 ^
-pix_fmt yuv420p ^
-c:v libvpx-vp9 ^
-s 800x600 -keyint_min 25 -g 25 %VP9_LIVE_PARAMS% ^
-f webm_chunk ^
-header "webm_live/glass_360.hdr" ^
-chunk_start_index 1 ^
webm_live\glass_360_%%d.chk ^
创建清单:
ffmpeg ^
-f webm_dash_manifest -live 1 ^
-r 25 ^
-i webm_live/glass_360.hdr ^
-c copy ^
-map 0 ^
-r 25 ^
-framerate 25 ^
-f webm_dash_manifest -live 1 ^
-adaptation_sets "id=0,streams=0" ^
-chunk_start_index 1 ^
-chunk_duration_ms 1000 ^
-time_shift_buffer_depth 7200 ^
-minimum_update_period 7200 ^
webm_live/glass_live_manifest.mpd
清单:
<?xml version="1.0" encoding="UTF-8"?>
<MPD
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="urn:mpeg:DASH:schema:MPD:2011"
xsi:schemaLocation="urn:mpeg:DASH:schema:MPD:2011"
type="dynamic"
minBufferTime="PT1S"
profiles="urn:mpeg:dash:profile:isoff-live:2011"
availabilityStartTime="2016-03-30T13:02:53Z"
timeShiftBufferDepth="PT7200S"
minimumUpdatePeriod="PT7200S">
<Period id="0" start="PT0S" >
<AdaptationSet id="0" mimeType="video/webm" codecs="vp9" bitstreamSwitching="true" subsegmentAlignment="true" subsegmentStartsWithSAP="1">
<ContentComponent id="1" type="video"/>
<SegmentTemplate timescale="1000" duration="1000" media="glass_$RepresentationID$_$Number$.chk" startNumber="1" initialization="glass_$RepresentationID$.hdr"/>
<Representation id="360" bandwidth="1000000" width="800" height="600" codecs="vp9" mimeType="video/webm" startsWithSAP="1"></Representation>
</AdaptationSet>
</Period>
</MPD>
任何想法如何解决这个问题?