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/test/rtp_packet_builder.h" | 5 #include "media/cast/net/rtp/rtp_packet_builder.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 | 9 |
10 namespace media { | 10 namespace media { |
11 namespace cast { | 11 namespace cast { |
12 | 12 |
13 const uint32 kCastRtpHeaderLength = 7; | 13 const uint32 kCastRtpHeaderLength = 7; |
14 const uint32 kGenericRtpHeaderLength = 12; | 14 const uint32 kGenericRtpHeaderLength = 12; |
15 static const uint8 kRtpMarkerBitMask = 0x80; | 15 static const uint8 kRtpMarkerBitMask = 0x80; |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 base::BigEndianWriter big_endian_writer(reinterpret_cast<char*>(data), 96); | 85 base::BigEndianWriter big_endian_writer(reinterpret_cast<char*>(data), 96); |
86 big_endian_writer.WriteU8(0x80); | 86 big_endian_writer.WriteU8(0x80); |
87 big_endian_writer.WriteU8(payload_type_ | (marker_ ? kRtpMarkerBitMask : 0)); | 87 big_endian_writer.WriteU8(payload_type_ | (marker_ ? kRtpMarkerBitMask : 0)); |
88 big_endian_writer.WriteU16(sequence_number_); | 88 big_endian_writer.WriteU16(sequence_number_); |
89 big_endian_writer.WriteU32(timestamp_); | 89 big_endian_writer.WriteU32(timestamp_); |
90 big_endian_writer.WriteU32(ssrc_); | 90 big_endian_writer.WriteU32(ssrc_); |
91 } | 91 } |
92 | 92 |
93 } // namespace cast | 93 } // namespace cast |
94 } // namespace media | 94 } // namespace media |
OLD | NEW |