Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(67)

Unified Diff: webrtc/modules/rtp_rtcp/source/rtcp_sender.cc

Issue 1959013003: TMMBRHelp moved from member object/base class to stack object, (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: includes adjusted Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtcp_sender.h ('k') | webrtc/modules/rtp_rtcp/source/tmmbr_help.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/rtp_rtcp/source/rtcp_sender.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtcp_sender.cc b/webrtc/modules/rtp_rtcp/source/rtcp_sender.cc
index 4a509b001ea0db5d438268b6011a163096f6abee..7113807cf86ea0150931a3551caa687cbcc7c69b 100644
--- a/webrtc/modules/rtp_rtcp/source/rtcp_sender.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtcp_sender.cc
@@ -36,6 +36,7 @@
#include "webrtc/modules/rtp_rtcp/source/rtcp_packet/tmmbr.h"
#include "webrtc/modules/rtp_rtcp/source/rtcp_packet/transport_feedback.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.h"
+#include "webrtc/modules/rtp_rtcp/source/tmmbr_help.h"
namespace webrtc {
@@ -169,7 +170,6 @@ RTCPSender::RTCPSender(
remb_bitrate_(0),
- tmmbr_help_(),
tmmbr_send_(0),
packet_oh_send_(0),
max_payload_length_(IP_PACKET_SIZE - 28), // IPv4 + UDP by default.
@@ -585,10 +585,11 @@ std::unique_ptr<rtcp::RtcpPacket> RTCPSender::BuildTMMBR(
// * If the sender is an owner of the TMMBN -> send TMMBR
// * If not an owner but the TMMBR would enter the TMMBN -> send TMMBR
+ TMMBRHelp tmmbr_help;
// get current bounding set from RTCP receiver
bool tmmbrOwner = false;
// store in candidateSet, allocates one extra slot
- TMMBRSet* candidateSet = tmmbr_help_.CandidateSet();
+ TMMBRSet* candidateSet = tmmbr_help.CandidateSet();
// holding critical_section_rtcp_sender_ while calling RTCPreceiver which
// will accuire criticalSectionRTCPReceiver_ is a potental deadlock but
@@ -613,9 +614,9 @@ std::unique_ptr<rtcp::RtcpPacket> RTCPSender::BuildTMMBR(
// find bounding set
TMMBRSet* boundingSet = nullptr;
- int numBoundingSet = tmmbr_help_.FindTMMBRBoundingSet(boundingSet);
+ int numBoundingSet = tmmbr_help.FindTMMBRBoundingSet(boundingSet);
if (numBoundingSet > 0 || numBoundingSet <= numCandidates)
- tmmbrOwner = tmmbr_help_.IsOwner(ssrc_, numBoundingSet);
+ tmmbrOwner = tmmbr_help.IsOwner(ssrc_, numBoundingSet);
if (!tmmbrOwner) {
// Did not enter bounding set, no meaning to send this request.
return nullptr;
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtcp_sender.h ('k') | webrtc/modules/rtp_rtcp/source/tmmbr_help.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698