mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
RTC: fix rtc publisher pli cid (#3318)
* RTC: fix rtc publisher pli cid * RTC: log bridge request keyframe * Update release v6.0.19 v5.0.138 Co-authored-by: Winlin <winlin@vip.126.com> Co-authored-by: ChenGH <chengh_math@126.com>
This commit is contained in:
parent
81566868bf
commit
7922057467
7 changed files with 14 additions and 10 deletions
|
@ -8,6 +8,7 @@ The changelog for SRS.
|
||||||
|
|
||||||
## SRS 6.0 Changelog
|
## SRS 6.0 Changelog
|
||||||
|
|
||||||
|
* v6.0, 2023-01-19, Merge [#3318](https://github.com/ossrs/srs/pull/3318): RTC: fix rtc publisher pli cid. v6.0.19 (#3318)
|
||||||
* v6.0, 2023-01-18, Merge [#3382](https://github.com/ossrs/srs/pull/3382): Rewrite research/api-server code by Go, remove Python. v6.0.18 (#3382)
|
* v6.0, 2023-01-18, Merge [#3382](https://github.com/ossrs/srs/pull/3382): Rewrite research/api-server code by Go, remove Python. v6.0.18 (#3382)
|
||||||
* v6.0, 2023-01-18, Merge [#3386](https://github.com/ossrs/srs/pull/3386): SRT: fix crash when srt_to_rtmp off. v6.0.17 (#3386)
|
* v6.0, 2023-01-18, Merge [#3386](https://github.com/ossrs/srs/pull/3386): SRT: fix crash when srt_to_rtmp off. v6.0.17 (#3386)
|
||||||
* v5.0, 2023-01-17, Merge [#3385](https://github.com/ossrs/srs/pull/3385): API: Support server/pid/service label for exporter and api. v6.0.16 (#3385)
|
* v5.0, 2023-01-17, Merge [#3385](https://github.com/ossrs/srs/pull/3385): API: Support server/pid/service label for exporter and api. v6.0.16 (#3385)
|
||||||
|
@ -32,6 +33,7 @@ The changelog for SRS.
|
||||||
|
|
||||||
## SRS 5.0 Changelog
|
## SRS 5.0 Changelog
|
||||||
|
|
||||||
|
* v5.0, 2023-01-19, Merge [#3318](https://github.com/ossrs/srs/pull/3318): RTC: fix rtc publisher pli cid. v5.0.138 (#3318)
|
||||||
* v5.0, 2023-01-18, Merge [#3382](https://github.com/ossrs/srs/pull/3382): Rewrite research/api-server code by Go, remove Python. v5.0.137 (#3382)
|
* v5.0, 2023-01-18, Merge [#3382](https://github.com/ossrs/srs/pull/3382): Rewrite research/api-server code by Go, remove Python. v5.0.137 (#3382)
|
||||||
* v5.0, 2023-01-18, Merge [#3386](https://github.com/ossrs/srs/pull/3386): SRT: fix crash when srt_to_rtmp off. v5.0.136 (#3386)
|
* v5.0, 2023-01-18, Merge [#3386](https://github.com/ossrs/srs/pull/3386): SRT: fix crash when srt_to_rtmp off. v5.0.136 (#3386)
|
||||||
* v5.0, 2023-01-17, Merge [#3385](https://github.com/ossrs/srs/pull/3385): API: Support server/pid/service label for exporter and api. v5.0.135 (#3385)
|
* v5.0, 2023-01-17, Merge [#3385](https://github.com/ossrs/srs/pull/3385): API: Support server/pid/service label for exporter and api. v5.0.135 (#3385)
|
||||||
|
|
|
@ -912,7 +912,7 @@ srs_error_t SrsRtcPlayStream::do_request_keyframe(uint32_t ssrc, SrsContextId ci
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
|
||||||
publisher->request_keyframe(ssrc);
|
publisher->request_keyframe(ssrc, cid);
|
||||||
|
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
@ -1611,15 +1611,14 @@ srs_error_t SrsRtcPublishStream::on_rtcp_xr(SrsRtcpXr* rtcp)
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SrsRtcPublishStream::request_keyframe(uint32_t ssrc)
|
void SrsRtcPublishStream::request_keyframe(uint32_t ssrc, SrsContextId cid)
|
||||||
{
|
{
|
||||||
SrsContextId sub_cid = _srs_context->get_id();
|
pli_worker_->request_keyframe(ssrc, cid);
|
||||||
pli_worker_->request_keyframe(ssrc, sub_cid);
|
|
||||||
|
|
||||||
uint32_t nn = 0;
|
uint32_t nn = 0;
|
||||||
if (pli_epp->can_print(ssrc, &nn)) {
|
if (pli_epp->can_print(ssrc, &nn)) {
|
||||||
// The player(subscriber) cid, which requires PLI.
|
// The player(subscriber) cid, which requires PLI.
|
||||||
srs_trace("RTC: Need PLI ssrc=%u, play=[%s], publish=[%s], count=%u/%u", ssrc, sub_cid.c_str(),
|
srs_trace("RTC: Need PLI ssrc=%u, play=[%s], publish=[%s], count=%u/%u", ssrc, cid.c_str(),
|
||||||
cid_.c_str(), nn, pli_epp->nn_count);
|
cid_.c_str(), nn, pli_epp->nn_count);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -384,7 +384,7 @@ private:
|
||||||
srs_error_t on_rtcp_sr(SrsRtcpSR* rtcp);
|
srs_error_t on_rtcp_sr(SrsRtcpSR* rtcp);
|
||||||
srs_error_t on_rtcp_xr(SrsRtcpXr* rtcp);
|
srs_error_t on_rtcp_xr(SrsRtcpXr* rtcp);
|
||||||
public:
|
public:
|
||||||
void request_keyframe(uint32_t ssrc);
|
void request_keyframe(uint32_t ssrc, SrsContextId cid);
|
||||||
virtual srs_error_t do_request_keyframe(uint32_t ssrc, SrsContextId cid);
|
virtual srs_error_t do_request_keyframe(uint32_t ssrc, SrsContextId cid);
|
||||||
public:
|
public:
|
||||||
void simulate_nack_drop(int nn);
|
void simulate_nack_drop(int nn);
|
||||||
|
|
|
@ -703,7 +703,8 @@ srs_error_t SrsRtcSource::on_timer(srs_utime_t interval)
|
||||||
|
|
||||||
for (int i = 0; i < (int)stream_desc_->video_track_descs_.size(); i++) {
|
for (int i = 0; i < (int)stream_desc_->video_track_descs_.size(); i++) {
|
||||||
SrsRtcTrackDescription* desc = stream_desc_->video_track_descs_.at(i);
|
SrsRtcTrackDescription* desc = stream_desc_->video_track_descs_.at(i);
|
||||||
publish_stream_->request_keyframe(desc->ssrc_);
|
srs_trace("RTC: to rtmp bridge request key frame, ssrc=%u, publisher cid=%s", desc->ssrc_, publish_stream_->context_id().c_str());
|
||||||
|
publish_stream_->request_keyframe(desc->ssrc_, publish_stream_->context_id());
|
||||||
}
|
}
|
||||||
|
|
||||||
return err;
|
return err;
|
||||||
|
|
|
@ -128,7 +128,9 @@ public:
|
||||||
virtual ~ISrsRtcPublishStream();
|
virtual ~ISrsRtcPublishStream();
|
||||||
public:
|
public:
|
||||||
// Request keyframe(PLI) from publisher, for fresh consumer.
|
// Request keyframe(PLI) from publisher, for fresh consumer.
|
||||||
virtual void request_keyframe(uint32_t ssrc) = 0;
|
virtual void request_keyframe(uint32_t ssrc, SrsContextId cid) = 0;
|
||||||
|
// Get context id.
|
||||||
|
virtual const SrsContextId& context_id() = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
class ISrsRtcSourceEventHandler
|
class ISrsRtcSourceEventHandler
|
||||||
|
|
|
@ -9,6 +9,6 @@
|
||||||
|
|
||||||
#define VERSION_MAJOR 5
|
#define VERSION_MAJOR 5
|
||||||
#define VERSION_MINOR 0
|
#define VERSION_MINOR 0
|
||||||
#define VERSION_REVISION 137
|
#define VERSION_REVISION 138
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -9,6 +9,6 @@
|
||||||
|
|
||||||
#define VERSION_MAJOR 6
|
#define VERSION_MAJOR 6
|
||||||
#define VERSION_MINOR 0
|
#define VERSION_MINOR 0
|
||||||
#define VERSION_REVISION 18
|
#define VERSION_REVISION 19
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue