mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-13 13:50:40 +01:00
Don't try to send REMB or VideoBitrateAllocation when RTCP is off.
Bug: webrtc:12978 Change-Id: I0bd9cb239c9d74695c1408dde985c92b2834ba2d Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/225961 Reviewed-by: Erik Språng <sprang@webrtc.org> Commit-Queue: Philipp Hancke <phancke@nvidia.com> Cr-Commit-Position: refs/heads/master@{#34610}
This commit is contained in:
parent
af9a3c6676
commit
c219a53c80
1 changed files with 8 additions and 0 deletions
|
@ -282,6 +282,10 @@ int32_t RTCPSender::SendLossNotification(const FeedbackState& feedback_state,
|
|||
void RTCPSender::SetRemb(int64_t bitrate_bps, std::vector<uint32_t> ssrcs) {
|
||||
RTC_CHECK_GE(bitrate_bps, 0);
|
||||
MutexLock lock(&mutex_rtcp_sender_);
|
||||
if (method_ == RtcpMode::kOff) {
|
||||
RTC_LOG(LS_WARNING) << "Can't send rtcp if it is disabled.";
|
||||
return;
|
||||
}
|
||||
remb_bitrate_ = bitrate_bps;
|
||||
remb_ssrcs_ = std::move(ssrcs);
|
||||
|
||||
|
@ -887,6 +891,10 @@ bool RTCPSender::AllVolatileFlagsConsumed() const {
|
|||
void RTCPSender::SetVideoBitrateAllocation(
|
||||
const VideoBitrateAllocation& bitrate) {
|
||||
MutexLock lock(&mutex_rtcp_sender_);
|
||||
if (method_ == RtcpMode::kOff) {
|
||||
RTC_LOG(LS_WARNING) << "Can't send rtcp if it is disabled.";
|
||||
return;
|
||||
}
|
||||
// Check if this allocation is first ever, or has a different set of
|
||||
// spatial/temporal layers signaled and enabled, if so trigger an rtcp report
|
||||
// as soon as possible.
|
||||
|
|
Loading…
Reference in a new issue