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

Side by Side Diff: webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc

Issue 1373903003: Unify newapi::RtcpMode and RTCPMethod. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: enum class Created 5 years, 2 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 25 matching lines...) Expand all
36 Clock* clock, 36 Clock* clock,
37 bool receiver_only, 37 bool receiver_only,
38 RtcpPacketTypeCounterObserver* packet_type_counter_observer, 38 RtcpPacketTypeCounterObserver* packet_type_counter_observer,
39 RtcpBandwidthObserver* rtcp_bandwidth_observer, 39 RtcpBandwidthObserver* rtcp_bandwidth_observer,
40 RtcpIntraFrameObserver* rtcp_intra_frame_observer, 40 RtcpIntraFrameObserver* rtcp_intra_frame_observer,
41 TransportFeedbackObserver* transport_feedback_observer, 41 TransportFeedbackObserver* transport_feedback_observer,
42 ModuleRtpRtcpImpl* owner) 42 ModuleRtpRtcpImpl* owner)
43 : TMMBRHelp(), 43 : TMMBRHelp(),
44 _clock(clock), 44 _clock(clock),
45 receiver_only_(receiver_only), 45 receiver_only_(receiver_only),
46 _method(kRtcpOff), 46 _method(RtcpMode::OFF),
47 _lastReceived(0), 47 _lastReceived(0),
48 _rtpRtcp(*owner), 48 _rtpRtcp(*owner),
49 _criticalSectionFeedbacks( 49 _criticalSectionFeedbacks(
50 CriticalSectionWrapper::CreateCriticalSection()), 50 CriticalSectionWrapper::CreateCriticalSection()),
51 _cbRtcpBandwidthObserver(rtcp_bandwidth_observer), 51 _cbRtcpBandwidthObserver(rtcp_bandwidth_observer),
52 _cbRtcpIntraFrameObserver(rtcp_intra_frame_observer), 52 _cbRtcpIntraFrameObserver(rtcp_intra_frame_observer),
53 _cbTransportFeedbackObserver(transport_feedback_observer), 53 _cbTransportFeedbackObserver(transport_feedback_observer),
54 _criticalSectionRTCPReceiver( 54 _criticalSectionRTCPReceiver(
55 CriticalSectionWrapper::CreateCriticalSection()), 55 CriticalSectionWrapper::CreateCriticalSection()),
56 main_ssrc_(0), 56 main_ssrc_(0),
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 _receivedInfoMap.erase(first); 92 _receivedInfoMap.erase(first);
93 } 93 }
94 while (!_receivedCnameMap.empty()) { 94 while (!_receivedCnameMap.empty()) {
95 std::map<uint32_t, RTCPCnameInformation*>::iterator first = 95 std::map<uint32_t, RTCPCnameInformation*>::iterator first =
96 _receivedCnameMap.begin(); 96 _receivedCnameMap.begin();
97 delete first->second; 97 delete first->second;
98 _receivedCnameMap.erase(first); 98 _receivedCnameMap.erase(first);
99 } 99 }
100 } 100 }
101 101
102 RTCPMethod RTCPReceiver::Status() const { 102 RtcpMode RTCPReceiver::Status() const {
103 CriticalSectionScoped lock(_criticalSectionRTCPReceiver); 103 CriticalSectionScoped lock(_criticalSectionRTCPReceiver);
104 return _method; 104 return _method;
105 } 105 }
106 106
107 void RTCPReceiver::SetRTCPStatus(RTCPMethod method) { 107 void RTCPReceiver::SetRTCPStatus(RtcpMode method) {
108 CriticalSectionScoped lock(_criticalSectionRTCPReceiver); 108 CriticalSectionScoped lock(_criticalSectionRTCPReceiver);
109 _method = method; 109 _method = method;
110 } 110 }
111 111
112 int64_t RTCPReceiver::LastReceived() { 112 int64_t RTCPReceiver::LastReceived() {
113 CriticalSectionScoped lock(_criticalSectionRTCPReceiver); 113 CriticalSectionScoped lock(_criticalSectionRTCPReceiver);
114 return _lastReceived; 114 return _lastReceived;
115 } 115 }
116 116
117 int64_t RTCPReceiver::LastReceivedReceiverReport() const { 117 int64_t RTCPReceiver::LastReceivedReceiverReport() const {
(...skipping 1372 matching lines...) Expand 10 before | Expand all | Expand 10 after
1490 return -1; 1490 return -1;
1491 } 1491 }
1492 num += receiveInfo->TmmbrSet.lengthOfSet(); 1492 num += receiveInfo->TmmbrSet.lengthOfSet();
1493 receiveInfoIt++; 1493 receiveInfoIt++;
1494 } 1494 }
1495 } 1495 }
1496 return num; 1496 return num;
1497 } 1497 }
1498 1498
1499 } // namespace webrtc 1499 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698