| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 14 matching lines...) Expand all Loading... |
| 25 class ReceiverReport : public RtcpPacket { | 25 class ReceiverReport : public RtcpPacket { |
| 26 public: | 26 public: |
| 27 static const uint8_t kPacketType = 201; | 27 static const uint8_t kPacketType = 201; |
| 28 ReceiverReport() : sender_ssrc_(0) {} | 28 ReceiverReport() : sender_ssrc_(0) {} |
| 29 | 29 |
| 30 ~ReceiverReport() override {} | 30 ~ReceiverReport() override {} |
| 31 | 31 |
| 32 // Parse assumes header is already parsed and validated. | 32 // Parse assumes header is already parsed and validated. |
| 33 bool Parse(const CommonHeader& packet); | 33 bool Parse(const CommonHeader& packet); |
| 34 | 34 |
| 35 void From(uint32_t ssrc) { sender_ssrc_ = ssrc; } | 35 void SetSenderSsrc(uint32_t ssrc) { sender_ssrc_ = ssrc; } |
| 36 bool WithReportBlock(const ReportBlock& block); | 36 bool AddReportBlock(const ReportBlock& block); |
| 37 | 37 |
| 38 uint32_t sender_ssrc() const { return sender_ssrc_; } | 38 uint32_t sender_ssrc() const { return sender_ssrc_; } |
| 39 const std::vector<ReportBlock>& report_blocks() const { | 39 const std::vector<ReportBlock>& report_blocks() const { |
| 40 return report_blocks_; | 40 return report_blocks_; |
| 41 } | 41 } |
| 42 | 42 |
| 43 protected: | 43 protected: |
| 44 bool Create(uint8_t* packet, | 44 bool Create(uint8_t* packet, |
| 45 size_t* index, | 45 size_t* index, |
| 46 size_t max_length, | 46 size_t max_length, |
| (...skipping 10 matching lines...) Expand all Loading... |
| 57 | 57 |
| 58 uint32_t sender_ssrc_; | 58 uint32_t sender_ssrc_; |
| 59 std::vector<ReportBlock> report_blocks_; | 59 std::vector<ReportBlock> report_blocks_; |
| 60 | 60 |
| 61 RTC_DISALLOW_COPY_AND_ASSIGN(ReceiverReport); | 61 RTC_DISALLOW_COPY_AND_ASSIGN(ReceiverReport); |
| 62 }; | 62 }; |
| 63 | 63 |
| 64 } // namespace rtcp | 64 } // namespace rtcp |
| 65 } // namespace webrtc | 65 } // namespace webrtc |
| 66 #endif // WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_PACKET_RECEIVER_REPORT_H_ | 66 #endif // WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_PACKET_RECEIVER_REPORT_H_ |
| OLD | NEW |