OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef MEDIA_CAST_RTCP_RTCP_UTILITY_H_ | 5 #ifndef MEDIA_CAST_NET_RTCP_RTCP_UTILITY_H_ |
6 #define MEDIA_CAST_RTCP_RTCP_UTILITY_H_ | 6 #define MEDIA_CAST_NET_RTCP_RTCP_UTILITY_H_ |
7 | 7 |
8 #include "base/big_endian.h" | 8 #include "base/big_endian.h" |
9 #include "media/cast/logging/logging_defines.h" | 9 #include "media/cast/logging/logging_defines.h" |
10 #include "media/cast/net/cast_transport_config.h" | 10 #include "media/cast/net/cast_transport_config.h" |
11 #include "media/cast/net/rtcp/rtcp_defines.h" | 11 #include "media/cast/net/rtcp/rtcp_defines.h" |
12 | 12 |
13 namespace media { | 13 namespace media { |
14 namespace cast { | 14 namespace cast { |
15 | 15 |
16 // RFC 3550 page 44, including end null. | 16 // RFC 3550 page 44, including end null. |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 // Maps a base::TimeTicks value to an NTP timestamp comprised of two components. | 128 // Maps a base::TimeTicks value to an NTP timestamp comprised of two components. |
129 void ConvertTimeTicksToNtp(const base::TimeTicks& time, | 129 void ConvertTimeTicksToNtp(const base::TimeTicks& time, |
130 uint32_t* ntp_seconds, | 130 uint32_t* ntp_seconds, |
131 uint32_t* ntp_fractions); | 131 uint32_t* ntp_fractions); |
132 | 132 |
133 // Maps an NTP timestamp, comprised of two components, to a base::TimeTicks | 133 // Maps an NTP timestamp, comprised of two components, to a base::TimeTicks |
134 // value. | 134 // value. |
135 base::TimeTicks ConvertNtpToTimeTicks(uint32_t ntp_seconds, | 135 base::TimeTicks ConvertNtpToTimeTicks(uint32_t ntp_seconds, |
136 uint32_t ntp_fractions); | 136 uint32_t ntp_fractions); |
137 | 137 |
| 138 bool IsRtcpPacket(const uint8_t* packet, size_t length); |
| 139 |
| 140 uint32_t GetSsrcOfSender(const uint8_t* rtcp_buffer, size_t length); |
| 141 |
138 } // namespace cast | 142 } // namespace cast |
139 } // namespace media | 143 } // namespace media |
140 | 144 |
141 #endif // MEDIA_CAST_RTCP_RTCP_UTILITY_H_ | 145 #endif // MEDIA_CAST_NET_RTCP_RTCP_UTILITY_H_ |
OLD | NEW |