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

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

Issue 2986893002: Piggybacking simulcast id and ALR experiment id into video content type extension. (Closed)
Patch Set: use namespace instead of struct Created 3 years, 3 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
« no previous file with comments | « webrtc/modules/pacing/alr_detector.cc ('k') | webrtc/modules/rtp_rtcp/source/rtp_utility.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 10
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 225 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
226 // | ID | len=0 | Content type | 226 // | ID | len=0 | Content type |
227 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 227 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
228 constexpr RTPExtensionType VideoContentTypeExtension::kId; 228 constexpr RTPExtensionType VideoContentTypeExtension::kId;
229 constexpr uint8_t VideoContentTypeExtension::kValueSizeBytes; 229 constexpr uint8_t VideoContentTypeExtension::kValueSizeBytes;
230 constexpr const char VideoContentTypeExtension::kUri[]; 230 constexpr const char VideoContentTypeExtension::kUri[];
231 231
232 bool VideoContentTypeExtension::Parse(rtc::ArrayView<const uint8_t> data, 232 bool VideoContentTypeExtension::Parse(rtc::ArrayView<const uint8_t> data,
233 VideoContentType* content_type) { 233 VideoContentType* content_type) {
234 if (data.size() == 1 && 234 if (data.size() == 1 &&
235 data[0] < static_cast<uint8_t>(VideoContentType::TOTAL_CONTENT_TYPES)) { 235 videocontenttypehelpers::IsValidContentType(data[0])) {
236 *content_type = static_cast<VideoContentType>(data[0]); 236 *content_type = static_cast<VideoContentType>(data[0]);
237 return true; 237 return true;
238 } 238 }
239 return false; 239 return false;
240 } 240 }
241 241
242 bool VideoContentTypeExtension::Write(uint8_t* data, 242 bool VideoContentTypeExtension::Write(uint8_t* data,
243 VideoContentType content_type) { 243 VideoContentType content_type) {
244 data[0] = static_cast<uint8_t>(content_type); 244 data[0] = static_cast<uint8_t>(content_type);
245 return true; 245 return true;
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 constexpr RTPExtensionType RtpStreamId::kId; 374 constexpr RTPExtensionType RtpStreamId::kId;
375 constexpr const char RtpStreamId::kUri[]; 375 constexpr const char RtpStreamId::kUri[];
376 376
377 constexpr RTPExtensionType RepairedRtpStreamId::kId; 377 constexpr RTPExtensionType RepairedRtpStreamId::kId;
378 constexpr const char RepairedRtpStreamId::kUri[]; 378 constexpr const char RepairedRtpStreamId::kUri[];
379 379
380 constexpr RTPExtensionType RtpMid::kId; 380 constexpr RTPExtensionType RtpMid::kId;
381 constexpr const char RtpMid::kUri[]; 381 constexpr const char RtpMid::kUri[];
382 382
383 } // namespace webrtc 383 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/pacing/alr_detector.cc ('k') | webrtc/modules/rtp_rtcp/source/rtp_utility.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698