1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Update readme for SRT

This commit is contained in:
winlin 2020-01-26 14:17:42 +08:00
commit 88c9c13707
4 changed files with 33 additions and 13 deletions

View file

@ -751,11 +751,9 @@ srs_error_t SrsHlsMuxer::_refresh_m3u8(string m3u8_file)
// #EXTM3U\n
// #EXT-X-VERSION:3\n
// #EXT-X-ALLOW-CACHE:YES\n
std::stringstream ss;
ss << "#EXTM3U" << SRS_CONSTS_LF
<< "#EXT-X-VERSION:3" << SRS_CONSTS_LF
<< "#EXT-X-ALLOW-CACHE:YES" << SRS_CONSTS_LF;
ss << "#EXTM3U" << SRS_CONSTS_LF;
ss << "#EXT-X-VERSION:3" << SRS_CONSTS_LF;
// #EXT-X-MEDIA-SEQUENCE:4294967295\n
SrsHlsSegment* first = dynamic_cast<SrsHlsSegment*>(segments->first());

View file

@ -1047,6 +1047,12 @@ srs_error_t SrsOriginHub::on_video(SrsSharedPtrMessage* shared_video, bool is_se
srs_avc_level2str(c->avc_level).c_str(), c->width, c->height,
c->video_data_rate / 1000, c->frame_rate, c->duration);
}
// Ignore video data when no sps/pps
// @bug https://github.com/ossrs/srs/issues/703#issuecomment-578393155
if (format->vcodec && !format->vcodec->is_avc_codec_ok()) {
return err;
}
if ((err = hls->on_video(msg, format)) != srs_success) {
// apply the error strategy for hls.