Allowing buffering a LNTF (loss notification) feedback message in RTCPSender
Loss notifications may either be sent immediately, or wait until another RTCP feedback message is sent. Bug: webrtc:10336 Change-Id: I40601d9fa1dec6c17b2ce905cb0c8cd2dcff7893 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/139242 Commit-Queue: Elad Alon <eladalon@webrtc.org> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28142}
This commit is contained in:
@ -215,7 +215,8 @@ int32_t RTCPSender::SetSendingStatus(const FeedbackState& feedback_state,
|
||||
int32_t RTCPSender::SendLossNotification(const FeedbackState& feedback_state,
|
||||
uint16_t last_decoded_seq_num,
|
||||
uint16_t last_received_seq_num,
|
||||
bool decodability_flag) {
|
||||
bool decodability_flag,
|
||||
bool buffering_allowed) {
|
||||
rtc::CritScope lock(&critical_section_rtcp_sender_);
|
||||
|
||||
loss_notification_state_.last_decoded_seq_num = last_decoded_seq_num;
|
||||
@ -224,7 +225,11 @@ int32_t RTCPSender::SendLossNotification(const FeedbackState& feedback_state,
|
||||
|
||||
SetFlag(kRtcpLossNotification, /*is_volatile=*/true);
|
||||
|
||||
// Send immediately.
|
||||
if (buffering_allowed) {
|
||||
// The loss notification will be batched with additional feedback messages.
|
||||
return 0;
|
||||
}
|
||||
|
||||
return SendCompoundRTCP(feedback_state,
|
||||
{RTCPPacketType::kRtcpLossNotification});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user