blob: dbdee0c126474b364eb1d0673754ce5baef5b743 [file] [log] [blame]
niklase@google.com470e71d2011-07-07 08:21:25 +00001/*
pwestin@webrtc.orgf6bb77a2012-01-24 17:16:59 +00002 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
niklase@google.com470e71d2011-07-07 08:21:25 +00003 *
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
11#ifndef WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_SENDER_H_
12#define WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_SENDER_H_
13
pwestin@webrtc.org26f8d9c2012-01-19 15:53:09 +000014#include <map>
edjee@google.com79b02892013-04-04 19:43:34 +000015#include <sstream>
16#include <string>
pwestin@webrtc.org26f8d9c2012-01-19 15:53:09 +000017
kwiberg@webrtc.org00b8f6b2015-02-26 14:34:55 +000018#include "webrtc/base/scoped_ptr.h"
pbos@webrtc.org38344ed2014-09-24 06:05:00 +000019#include "webrtc/base/thread_annotations.h"
pbos@webrtc.orga048d7c2013-05-29 14:27:38 +000020#include "webrtc/modules/remote_bitrate_estimator/include/bwe_defines.h"
21#include "webrtc/modules/remote_bitrate_estimator/include/remote_bitrate_estimator.h"
wu@webrtc.org822fbd82013-08-15 23:38:54 +000022#include "webrtc/modules/rtp_rtcp/interface/receive_statistics.h"
pbos@webrtc.orga048d7c2013-05-29 14:27:38 +000023#include "webrtc/modules/rtp_rtcp/interface/rtp_rtcp_defines.h"
24#include "webrtc/modules/rtp_rtcp/source/rtcp_utility.h"
25#include "webrtc/modules/rtp_rtcp/source/rtp_utility.h"
26#include "webrtc/modules/rtp_rtcp/source/tmmbr_help.h"
pbos@webrtc.orga048d7c2013-05-29 14:27:38 +000027#include "webrtc/typedefs.h"
niklase@google.com470e71d2011-07-07 08:21:25 +000028
29namespace webrtc {
pwestin@webrtc.org741da942011-09-20 13:52:04 +000030
wu@webrtc.org822fbd82013-08-15 23:38:54 +000031class ModuleRtpRtcpImpl;
pbos@webrtc.org59f20bb2013-09-09 16:02:19 +000032class RTCPReceiver;
pwestin@webrtc.org741da942011-09-20 13:52:04 +000033
asapersson@webrtc.org9ffd8fe2015-01-21 08:22:50 +000034class NACKStringBuilder {
35 public:
36 NACKStringBuilder();
37 ~NACKStringBuilder();
pbos@webrtc.orgf3e4cee2013-07-31 15:17:19 +000038
asapersson@webrtc.org9ffd8fe2015-01-21 08:22:50 +000039 void PushNACK(uint16_t nack);
40 std::string GetResult();
edjee@google.com79b02892013-04-04 19:43:34 +000041
asapersson@webrtc.org9ffd8fe2015-01-21 08:22:50 +000042 private:
43 std::ostringstream _stream;
44 int _count;
45 uint16_t _prevNack;
46 bool _consecutive;
edjee@google.com79b02892013-04-04 19:43:34 +000047};
48
asapersson@webrtc.org9ffd8fe2015-01-21 08:22:50 +000049class RTCPSender {
niklase@google.com470e71d2011-07-07 08:21:25 +000050public:
pbos@webrtc.org59f20bb2013-09-09 16:02:19 +000051 struct FeedbackState {
pbos@webrtc.org59f20bb2013-09-09 16:02:19 +000052 FeedbackState();
53
54 uint8_t send_payload_type;
55 uint32_t frequency_hz;
pbos@webrtc.org2f4b14e2014-07-15 15:25:39 +000056 uint32_t packets_sent;
pkasting@chromium.org4591fbd2014-11-20 22:28:14 +000057 size_t media_bytes_sent;
pbos@webrtc.org59f20bb2013-09-09 16:02:19 +000058 uint32_t send_bitrate;
59
60 uint32_t last_rr_ntp_secs;
61 uint32_t last_rr_ntp_frac;
62 uint32_t remote_sr;
63
asapersson@webrtc.org8469f7b2013-10-02 13:15:34 +000064 bool has_last_xr_rr;
65 RtcpReceiveTimeInfo last_xr_rr;
66
pbos@webrtc.org59f20bb2013-09-09 16:02:19 +000067 // Used when generating TMMBR.
68 ModuleRtpRtcpImpl* module;
69 };
Erik Språng61be2a42015-04-27 13:32:52 +020070
pbos@webrtc.orgd16e8392014-12-19 13:49:55 +000071 RTCPSender(int32_t id,
72 bool audio,
73 Clock* clock,
pbos@webrtc.org1d0fa5d2015-02-19 12:47:00 +000074 ReceiveStatistics* receive_statistics,
75 RtcpPacketTypeCounterObserver* packet_type_counter_observer);
Erik Språng61be2a42015-04-27 13:32:52 +020076 virtual ~RTCPSender();
niklase@google.com470e71d2011-07-07 08:21:25 +000077
Erik Språng61be2a42015-04-27 13:32:52 +020078 int32_t RegisterSendTransport(Transport* outgoingTransport);
niklase@google.com470e71d2011-07-07 08:21:25 +000079
Erik Språng61be2a42015-04-27 13:32:52 +020080 RTCPMethod Status() const;
81 void SetRTCPStatus(RTCPMethod method);
niklase@google.com470e71d2011-07-07 08:21:25 +000082
Erik Språng61be2a42015-04-27 13:32:52 +020083 bool Sending() const;
84 int32_t SetSendingStatus(const FeedbackState& feedback_state,
85 bool enabled); // combine the functions
niklase@google.com470e71d2011-07-07 08:21:25 +000086
Erik Språng61be2a42015-04-27 13:32:52 +020087 int32_t SetNackStatus(bool enable);
niklase@google.com470e71d2011-07-07 08:21:25 +000088
Erik Språng61be2a42015-04-27 13:32:52 +020089 void SetStartTimestamp(uint32_t start_timestamp);
stefan@webrtc.org7c3523c2012-09-11 07:00:42 +000090
Erik Språng61be2a42015-04-27 13:32:52 +020091 void SetLastRtpTime(uint32_t rtp_timestamp, int64_t capture_time_ms);
stefan@webrtc.org7c3523c2012-09-11 07:00:42 +000092
Erik Språng61be2a42015-04-27 13:32:52 +020093 void SetSSRC(uint32_t ssrc);
niklase@google.com470e71d2011-07-07 08:21:25 +000094
Erik Språng61be2a42015-04-27 13:32:52 +020095 void SetRemoteSSRC(uint32_t ssrc);
niklase@google.com470e71d2011-07-07 08:21:25 +000096
Erik Språng61be2a42015-04-27 13:32:52 +020097 int32_t SetCNAME(const char cName[RTCP_CNAME_SIZE]);
niklase@google.com470e71d2011-07-07 08:21:25 +000098
Erik Språng61be2a42015-04-27 13:32:52 +020099 int32_t AddMixedCNAME(uint32_t SSRC, const char cName[RTCP_CNAME_SIZE]);
niklase@google.com470e71d2011-07-07 08:21:25 +0000100
Erik Språng61be2a42015-04-27 13:32:52 +0200101 int32_t RemoveMixedCNAME(uint32_t SSRC);
niklase@google.com470e71d2011-07-07 08:21:25 +0000102
Erik Språng61be2a42015-04-27 13:32:52 +0200103 int64_t SendTimeOfSendReport(uint32_t sendReport);
niklase@google.com470e71d2011-07-07 08:21:25 +0000104
Erik Språng61be2a42015-04-27 13:32:52 +0200105 bool SendTimeOfXrRrReport(uint32_t mid_ntp, int64_t* time_ms) const;
asapersson@webrtc.org8469f7b2013-10-02 13:15:34 +0000106
Erik Språng61be2a42015-04-27 13:32:52 +0200107 bool TimeToSendRTCPReport(bool sendKeyframeBeforeRTP = false) const;
niklase@google.com470e71d2011-07-07 08:21:25 +0000108
Erik Språng61be2a42015-04-27 13:32:52 +0200109 int32_t SendRTCP(const FeedbackState& feedback_state,
110 uint32_t rtcpPacketTypeFlags,
111 int32_t nackSize = 0,
112 const uint16_t* nackList = 0,
113 bool repeat = false,
114 uint64_t pictureID = 0);
niklase@google.com470e71d2011-07-07 08:21:25 +0000115
Erik Språng61be2a42015-04-27 13:32:52 +0200116 int32_t AddExternalReportBlock(uint32_t SSRC,
117 const RTCPReportBlock* receiveBlock);
niklase@google.com470e71d2011-07-07 08:21:25 +0000118
Erik Språng61be2a42015-04-27 13:32:52 +0200119 int32_t RemoveExternalReportBlock(uint32_t SSRC);
niklase@google.com470e71d2011-07-07 08:21:25 +0000120
Erik Språng61be2a42015-04-27 13:32:52 +0200121 bool REMB() const;
niklase@google.com470e71d2011-07-07 08:21:25 +0000122
Erik Språng61be2a42015-04-27 13:32:52 +0200123 void SetREMBStatus(bool enable);
pwestin@webrtc.org741da942011-09-20 13:52:04 +0000124
Erik Språng61be2a42015-04-27 13:32:52 +0200125 void SetREMBData(uint32_t bitrate, const std::vector<uint32_t>& ssrcs);
pwestin@webrtc.org741da942011-09-20 13:52:04 +0000126
Erik Språng61be2a42015-04-27 13:32:52 +0200127 bool TMMBR() const;
mflodman@webrtc.org84dc3d12011-12-22 10:26:13 +0000128
Erik Språng61be2a42015-04-27 13:32:52 +0200129 void SetTMMBRStatus(bool enable);
niklase@google.com470e71d2011-07-07 08:21:25 +0000130
Erik Språng61be2a42015-04-27 13:32:52 +0200131 int32_t SetTMMBN(const TMMBRSet* boundingSet, uint32_t maxBitrateKbit);
niklase@google.com470e71d2011-07-07 08:21:25 +0000132
Erik Språng61be2a42015-04-27 13:32:52 +0200133 // Extended jitter report
134 bool IJ() const;
niklase@google.com470e71d2011-07-07 08:21:25 +0000135
Erik Språng61be2a42015-04-27 13:32:52 +0200136 void SetIJStatus(bool enable);
asapersson@webrtc.org5249cc82011-12-16 14:31:37 +0000137
Erik Språng61be2a42015-04-27 13:32:52 +0200138 int32_t SetApplicationSpecificData(uint8_t subType,
139 uint32_t name,
140 const uint8_t* data,
141 uint16_t length);
142 int32_t SetRTCPVoIPMetrics(const RTCPVoIPMetric* VoIPMetric);
asapersson@webrtc.org5249cc82011-12-16 14:31:37 +0000143
Erik Språng61be2a42015-04-27 13:32:52 +0200144 void SendRtcpXrReceiverReferenceTime(bool enable);
niklase@google.com470e71d2011-07-07 08:21:25 +0000145
Erik Språng61be2a42015-04-27 13:32:52 +0200146 bool RtcpXrReceiverReferenceTime() const;
niklase@google.com470e71d2011-07-07 08:21:25 +0000147
Erik Språng61be2a42015-04-27 13:32:52 +0200148 void SetCsrcs(const std::vector<uint32_t>& csrcs);
niklase@google.com470e71d2011-07-07 08:21:25 +0000149
Erik Språng61be2a42015-04-27 13:32:52 +0200150 void SetTargetBitrate(unsigned int target_bitrate);
mflodman@webrtc.org117c1192012-01-13 08:52:58 +0000151
niklase@google.com470e71d2011-07-07 08:21:25 +0000152private:
pbos@webrtc.orgd16e8392014-12-19 13:49:55 +0000153 int32_t SendToNetwork(const uint8_t* dataBuffer, size_t length);
niklase@google.com470e71d2011-07-07 08:21:25 +0000154
pbos@webrtc.orgd16e8392014-12-19 13:49:55 +0000155 int32_t WriteAllReportBlocksToBuffer(uint8_t* rtcpbuffer,
156 int pos,
Erik Språng61be2a42015-04-27 13:32:52 +0200157 uint8_t* numberOfReportBlocks,
pbos@webrtc.orgd16e8392014-12-19 13:49:55 +0000158 uint32_t NTPsec,
159 uint32_t NTPfrac)
160 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000161
Erik Språng61be2a42015-04-27 13:32:52 +0200162 int32_t WriteReportBlocksToBuffer(
163 uint8_t* rtcpbuffer,
164 int32_t position,
165 const std::map<uint32_t, RTCPReportBlock*>& report_blocks);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000166
Erik Språng61be2a42015-04-27 13:32:52 +0200167 int32_t AddReportBlock(uint32_t SSRC,
168 std::map<uint32_t, RTCPReportBlock*>* report_blocks,
169 const RTCPReportBlock* receiveBlock);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000170
Erik Språng61be2a42015-04-27 13:32:52 +0200171 bool PrepareReport(const FeedbackState& feedback_state,
172 StreamStatistician* statistician,
173 RTCPReportBlock* report_block,
174 uint32_t* ntp_secs,
175 uint32_t* ntp_frac);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000176
Erik Språng61be2a42015-04-27 13:32:52 +0200177 int32_t BuildSR(const FeedbackState& feedback_state,
178 uint8_t* rtcpbuffer,
179 int32_t pos,
180 uint32_t NTPsec,
181 uint32_t NTPfrac)
182 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000183
Erik Språng61be2a42015-04-27 13:32:52 +0200184 int32_t BuildRR(uint8_t* rtcpbuffer,
185 int32_t pos,
186 uint32_t NTPsec,
187 uint32_t NTPfrac)
188 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000189
Erik Språng61be2a42015-04-27 13:32:52 +0200190 int PrepareRTCP(const FeedbackState& feedback_state,
191 uint32_t packetTypeFlags,
192 int32_t nackSize,
193 const uint16_t* nackList,
194 bool repeat,
195 uint64_t pictureID,
196 uint8_t* rtcp_buffer,
197 int buffer_size);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000198
Erik Språng61be2a42015-04-27 13:32:52 +0200199 bool ShouldSendReportBlocks(uint32_t rtcp_packet_type) const;
niklase@google.com470e71d2011-07-07 08:21:25 +0000200
Erik Språng61be2a42015-04-27 13:32:52 +0200201 int32_t BuildExtendedJitterReport(uint8_t* rtcpbuffer,
202 int32_t pos,
203 uint32_t jitterTransmissionTimeOffset)
204 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
asapersson@webrtc.org5249cc82011-12-16 14:31:37 +0000205
Erik Språng61be2a42015-04-27 13:32:52 +0200206 int32_t BuildSDEC(uint8_t* rtcpbuffer, int32_t pos)
207 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
208 int32_t BuildPLI(uint8_t* rtcpbuffer, int32_t pos)
209 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
210 int32_t BuildREMB(uint8_t* rtcpbuffer, int32_t pos)
211 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
212 int32_t BuildTMMBR(ModuleRtpRtcpImpl* module, uint8_t* rtcpbuffer, int32_t pos)
213 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
214 int32_t BuildTMMBN(uint8_t* rtcpbuffer, int32_t pos)
215 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
216 int32_t BuildAPP(uint8_t* rtcpbuffer, int32_t pos)
217 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
218 int32_t BuildVoIPMetric(uint8_t* rtcpbuffer, int32_t pos)
219 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
220 int32_t BuildBYE(uint8_t* rtcpbuffer, int32_t pos)
221 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
222 int32_t BuildFIR(uint8_t* rtcpbuffer, int32_t pos, bool repeat)
223 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
224 int32_t BuildSLI(uint8_t* rtcpbuffer, int32_t pos, uint8_t pictureID)
225 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
226 int32_t BuildRPSI(uint8_t* rtcpbuffer,
227 int32_t pos,
228 uint64_t pictureID,
229 uint8_t payloadType)
230 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000231
Erik Språng61be2a42015-04-27 13:32:52 +0200232 int32_t BuildNACK(uint8_t* rtcpbuffer,
233 int32_t pos,
234 int32_t nackSize,
235 const uint16_t* nackList,
236 std::string* nackString)
237 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
238 int32_t BuildReceiverReferenceTime(uint8_t* buffer,
239 int32_t pos,
240 uint32_t ntp_sec,
241 uint32_t ntp_frac)
242 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
243 int32_t BuildDlrr(uint8_t* buffer,
244 int32_t pos,
245 const RtcpReceiveTimeInfo& info)
246 EXCLUSIVE_LOCKS_REQUIRED(_criticalSectionRTCPSender);
asapersson@webrtc.org8469f7b2013-10-02 13:15:34 +0000247
niklase@google.com470e71d2011-07-07 08:21:25 +0000248private:
Erik Språng61be2a42015-04-27 13:32:52 +0200249 const int32_t _id;
250 const bool _audio;
251 Clock* const _clock;
252 RTCPMethod _method GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000253
Erik Språng61be2a42015-04-27 13:32:52 +0200254 rtc::scoped_ptr<CriticalSectionWrapper> _criticalSectionTransport;
255 Transport* _cbTransport GUARDED_BY(_criticalSectionTransport);
niklase@google.com470e71d2011-07-07 08:21:25 +0000256
Erik Språng61be2a42015-04-27 13:32:52 +0200257 rtc::scoped_ptr<CriticalSectionWrapper> _criticalSectionRTCPSender;
258 bool _usingNack GUARDED_BY(_criticalSectionRTCPSender);
259 bool _sending GUARDED_BY(_criticalSectionRTCPSender);
260 bool _sendTMMBN GUARDED_BY(_criticalSectionRTCPSender);
261 bool _REMB GUARDED_BY(_criticalSectionRTCPSender);
262 bool _sendREMB GUARDED_BY(_criticalSectionRTCPSender);
263 bool _TMMBR GUARDED_BY(_criticalSectionRTCPSender);
264 bool _IJ GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000265
Erik Språng61be2a42015-04-27 13:32:52 +0200266 int64_t _nextTimeToSendRTCP GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000267
Erik Språng61be2a42015-04-27 13:32:52 +0200268 uint32_t start_timestamp_ GUARDED_BY(_criticalSectionRTCPSender);
269 uint32_t last_rtp_timestamp_ GUARDED_BY(_criticalSectionRTCPSender);
270 int64_t last_frame_capture_time_ms_ GUARDED_BY(_criticalSectionRTCPSender);
271 uint32_t _SSRC GUARDED_BY(_criticalSectionRTCPSender);
272 // SSRC that we receive on our RTP channel
273 uint32_t _remoteSSRC GUARDED_BY(_criticalSectionRTCPSender);
274 char _CNAME[RTCP_CNAME_SIZE] GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000275
Erik Språng61be2a42015-04-27 13:32:52 +0200276 ReceiveStatistics* receive_statistics_ GUARDED_BY(_criticalSectionRTCPSender);
277 std::map<uint32_t, RTCPReportBlock*> internal_report_blocks_
278 GUARDED_BY(_criticalSectionRTCPSender);
279 std::map<uint32_t, RTCPReportBlock*> external_report_blocks_
280 GUARDED_BY(_criticalSectionRTCPSender);
281 std::map<uint32_t, RTCPUtility::RTCPCnameInformation*> _csrcCNAMEs
282 GUARDED_BY(_criticalSectionRTCPSender);
stefan@webrtc.org286fe0b2013-08-21 20:58:21 +0000283
Erik Språng61be2a42015-04-27 13:32:52 +0200284 // Sent
285 uint32_t _lastSendReport[RTCP_NUMBER_OF_SR] GUARDED_BY(
286 _criticalSectionRTCPSender); // allow packet loss and RTT above 1 sec
287 int64_t _lastRTCPTime[RTCP_NUMBER_OF_SR] GUARDED_BY(
288 _criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000289
Erik Språng61be2a42015-04-27 13:32:52 +0200290 // Sent XR receiver reference time report.
291 // <mid ntp (mid 32 bits of the 64 bits NTP timestamp), send time in ms>.
292 std::map<uint32_t, int64_t> last_xr_rr_ GUARDED_BY(_criticalSectionRTCPSender);
asapersson@webrtc.org8469f7b2013-10-02 13:15:34 +0000293
Erik Språng61be2a42015-04-27 13:32:52 +0200294 // send CSRCs
295 std::vector<uint32_t> csrcs_ GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000296
Erik Språng61be2a42015-04-27 13:32:52 +0200297 // Full intra request
298 uint8_t _sequenceNumberFIR GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000299
Erik Språng61be2a42015-04-27 13:32:52 +0200300 // REMB
301 uint32_t _rembBitrate GUARDED_BY(_criticalSectionRTCPSender);
302 std::vector<uint32_t> remb_ssrcs_ GUARDED_BY(_criticalSectionRTCPSender);
pwestin@webrtc.org741da942011-09-20 13:52:04 +0000303
Erik Språng61be2a42015-04-27 13:32:52 +0200304 TMMBRHelp _tmmbrHelp GUARDED_BY(_criticalSectionRTCPSender);
305 uint32_t _tmmbr_Send GUARDED_BY(_criticalSectionRTCPSender);
306 uint32_t _packetOH_Send GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000307
Erik Språng61be2a42015-04-27 13:32:52 +0200308 // APP
309 bool _appSend GUARDED_BY(_criticalSectionRTCPSender);
310 uint8_t _appSubType GUARDED_BY(_criticalSectionRTCPSender);
311 uint32_t _appName GUARDED_BY(_criticalSectionRTCPSender);
312 rtc::scoped_ptr<uint8_t[]> _appData GUARDED_BY(_criticalSectionRTCPSender);
313 uint16_t _appLength GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000314
Erik Språng61be2a42015-04-27 13:32:52 +0200315 // True if sending of XR Receiver reference time report is enabled.
316 bool xrSendReceiverReferenceTimeEnabled_
317 GUARDED_BY(_criticalSectionRTCPSender);
asapersson@webrtc.org8469f7b2013-10-02 13:15:34 +0000318
Erik Språng61be2a42015-04-27 13:32:52 +0200319 // XR VoIP metric
320 bool _xrSendVoIPMetric GUARDED_BY(_criticalSectionRTCPSender);
321 RTCPVoIPMetric _xrVoIPMetric GUARDED_BY(_criticalSectionRTCPSender);
edjee@google.com79b02892013-04-04 19:43:34 +0000322
Erik Språng61be2a42015-04-27 13:32:52 +0200323 RtcpPacketTypeCounterObserver* const packet_type_counter_observer_;
324 RtcpPacketTypeCounter packet_type_counter_
325 GUARDED_BY(_criticalSectionRTCPSender);
asapersson@webrtc.org2dd31342014-10-29 12:42:30 +0000326
Erik Språng61be2a42015-04-27 13:32:52 +0200327 RTCPUtility::NackStats nack_stats_ GUARDED_BY(_criticalSectionRTCPSender);
niklase@google.com470e71d2011-07-07 08:21:25 +0000328};
pbos@webrtc.orgd900e8b2013-07-03 15:12:26 +0000329} // namespace webrtc
niklase@google.com470e71d2011-07-07 08:21:25 +0000330
331#endif // WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_SENDER_H_