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

Side by Side Diff: webrtc/modules/rtp_rtcp/source/rtp_packet.h

Issue 2553863003: Parse FlexFEC RTP headers in Call and add integration with BWE. (Closed)
Patch Set: Add basic CongestionController unit test, based on nisse's suggestion. Created 4 years 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) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 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 #ifndef WEBRTC_MODULES_RTP_RTCP_SOURCE_RTP_PACKET_H_ 10 #ifndef WEBRTC_MODULES_RTP_RTCP_SOURCE_RTP_PACKET_H_
(...skipping 13 matching lines...) Expand all
24 24
25 namespace rtp { 25 namespace rtp {
26 class Packet { 26 class Packet {
27 public: 27 public:
28 using ExtensionType = RTPExtensionType; 28 using ExtensionType = RTPExtensionType;
29 using ExtensionManager = RtpHeaderExtensionMap; 29 using ExtensionManager = RtpHeaderExtensionMap;
30 static constexpr size_t kMaxExtensionHeaders = 14; 30 static constexpr size_t kMaxExtensionHeaders = 14;
31 31
32 // Parse and copy given buffer into Packet. 32 // Parse and copy given buffer into Packet.
33 bool Parse(const uint8_t* buffer, size_t size); 33 bool Parse(const uint8_t* buffer, size_t size);
34 bool Parse(rtc::ArrayView<const uint8_t> packet);
34 35
35 // Parse and move given buffer into Packet. 36 // Parse and move given buffer into Packet.
36 bool Parse(rtc::CopyOnWriteBuffer packet); 37 bool Parse(rtc::CopyOnWriteBuffer packet);
37 38
38 // Maps extensions id to their types. 39 // Maps extensions id to their types.
39 void IdentifyExtensions(const ExtensionManager& extensions); 40 void IdentifyExtensions(const ExtensionManager& extensions);
40 41
41 // Header. 42 // Header.
42 bool Marker() const; 43 bool Marker() const;
43 uint8_t PayloadType() const; 44 uint8_t PayloadType() const;
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 uint16_t offset = 0; 186 uint16_t offset = 0;
186 if (!AllocateExtension(Extension::kId, Extension::kValueSizeBytes, &offset)) 187 if (!AllocateExtension(Extension::kId, Extension::kValueSizeBytes, &offset))
187 return false; 188 return false;
188 memset(WriteAt(offset), 0, Extension::kValueSizeBytes); 189 memset(WriteAt(offset), 0, Extension::kValueSizeBytes);
189 return true; 190 return true;
190 } 191 }
191 } // namespace rtp 192 } // namespace rtp
192 } // namespace webrtc 193 } // namespace webrtc
193 194
194 #endif // WEBRTC_MODULES_RTP_RTCP_SOURCE_RTP_PACKET_H_ 195 #endif // WEBRTC_MODULES_RTP_RTCP_SOURCE_RTP_PACKET_H_
OLDNEW
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/flexfec_receiver_unittest.cc ('k') | webrtc/modules/rtp_rtcp/source/rtp_packet.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698