| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "media/cast/rtp_receiver/rtp_parser/rtp_parser.h" | 5 #include "media/cast/rtp_receiver/rtp_parser/rtp_parser.h" |
| 6 | 6 |
| 7 #include "base/big_endian.h" | 7 #include "base/big_endian.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "media/cast/cast_defines.h" | 9 #include "media/cast/cast_defines.h" |
| 10 #include "media/cast/rtp_receiver/rtp_receiver.h" | |
| 11 | 10 |
| 12 namespace media { | 11 namespace media { |
| 13 namespace cast { | 12 namespace cast { |
| 14 | 13 |
| 15 static const size_t kRtpHeaderLength = 12; | 14 static const size_t kRtpHeaderLength = 12; |
| 16 static const size_t kCastHeaderLength = 7; | 15 static const size_t kCastHeaderLength = 7; |
| 17 static const uint8 kRtpExtensionBitMask = 0x10; | 16 static const uint8 kRtpExtensionBitMask = 0x10; |
| 18 static const uint8 kRtpMarkerBitMask = 0x80; | 17 static const uint8 kRtpMarkerBitMask = 0x80; |
| 19 static const uint8 kCastKeyFrameBitMask = 0x80; | 18 static const uint8 kCastKeyFrameBitMask = 0x80; |
| 20 static const uint8 kCastReferenceFrameIdBitMask = 0x40; | 19 static const uint8 kCastReferenceFrameIdBitMask = 0x40; |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 | 109 |
| 111 // All remaining data in the packet is the payload. | 110 // All remaining data in the packet is the payload. |
| 112 *payload_data = reinterpret_cast<const uint8*>(reader.ptr()); | 111 *payload_data = reinterpret_cast<const uint8*>(reader.ptr()); |
| 113 *payload_size = reader.remaining(); | 112 *payload_size = reader.remaining(); |
| 114 | 113 |
| 115 return true; | 114 return true; |
| 116 } | 115 } |
| 117 | 116 |
| 118 } // namespace cast | 117 } // namespace cast |
| 119 } // namespace media | 118 } // namespace media |
| OLD | NEW |