| OLD | NEW |
| 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 Loading... |
| 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 Loading... |
| 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 |
| OLD | NEW |