diff options
author | danilchap <danilchap@webrtc.org> | 2015-11-22 09:03:11 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-11-22 17:03:16 +0000 |
commit | 50c5136cb2ad11eb9ba3df1a1d54d527c8a0dc77 (patch) | |
tree | 86a8a4141ab53eb73c40012f4bf6aa3b5b832b8b /webrtc/modules/rtp_rtcp/source/rtcp_packet.h | |
parent | c9829138c013e22b89ae2d896f25b8b35e80135d (diff) | |
download | webrtc-50c5136cb2ad11eb9ba3df1a1d54d527c8a0dc77.tar.gz |
RTCP Bye packet moved to own file
Bye class got support for Parsing
Reason field implemented
Review URL: https://codereview.webrtc.org/1430013003
Cr-Commit-Position: refs/heads/master@{#10741}
Diffstat (limited to 'webrtc/modules/rtp_rtcp/source/rtcp_packet.h')
-rw-r--r-- | webrtc/modules/rtp_rtcp/source/rtcp_packet.h | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/webrtc/modules/rtp_rtcp/source/rtcp_packet.h b/webrtc/modules/rtp_rtcp/source/rtcp_packet.h index bea83070cb..3ac66184bd 100644 --- a/webrtc/modules/rtp_rtcp/source/rtcp_packet.h +++ b/webrtc/modules/rtp_rtcp/source/rtcp_packet.h @@ -319,56 +319,6 @@ class Sdes : public RtcpPacket { RTC_DISALLOW_COPY_AND_ASSIGN(Sdes); }; -// -// Bye packet (BYE) (RFC 3550). -// -// 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 -// +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ -// |V=2|P| SC | PT=BYE=203 | length | -// +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ -// | SSRC/CSRC | -// +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ -// : ... : -// +=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ -// (opt) | length | reason for leaving ... -// +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ - -class Bye : public RtcpPacket { - public: - Bye() : RtcpPacket() { - memset(&bye_, 0, sizeof(bye_)); - } - - virtual ~Bye() {} - - void From(uint32_t ssrc) { - bye_.SenderSSRC = ssrc; - } - - bool WithCsrc(uint32_t csrc); - - // TODO(sprang): Add support for reason field? - - protected: - bool Create(uint8_t* packet, - size_t* index, - size_t max_length, - RtcpPacket::PacketReadyCallback* callback) const override; - - private: - static const int kMaxNumberOfCsrcs = 0x1f - 1; // First item is sender SSRC. - - size_t BlockLength() const { - size_t source_count = 1 + csrcs_.size(); - return kHeaderLength + 4 * source_count; - } - - RTCPUtility::RTCPPacketBYE bye_; - std::vector<uint32_t> csrcs_; - - RTC_DISALLOW_COPY_AND_ASSIGN(Bye); -}; - // RFC 4585: Feedback format. // // Common packet format: |