| 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 #ifndef MEDIA_CAST_RTCP_RTCP_H_ | 5 #ifndef MEDIA_CAST_RTCP_RTCP_H_ |
| 6 #define MEDIA_CAST_RTCP_RTCP_H_ | 6 #define MEDIA_CAST_RTCP_RTCP_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <queue> | 10 #include <queue> |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 const std::string& c_name, | 71 const std::string& c_name, |
| 72 bool is_audio); | 72 bool is_audio); |
| 73 | 73 |
| 74 virtual ~Rtcp(); | 74 virtual ~Rtcp(); |
| 75 | 75 |
| 76 static bool IsRtcpPacket(const uint8* rtcp_buffer, size_t length); | 76 static bool IsRtcpPacket(const uint8* rtcp_buffer, size_t length); |
| 77 | 77 |
| 78 static uint32 GetSsrcOfSender(const uint8* rtcp_buffer, size_t length); | 78 static uint32 GetSsrcOfSender(const uint8* rtcp_buffer, size_t length); |
| 79 | 79 |
| 80 base::TimeTicks TimeToSendNextRtcpReport(); | 80 base::TimeTicks TimeToSendNextRtcpReport(); |
| 81 void SendRtcpFromRtpSender(transport::RtcpSenderInfo sender_info); | 81 |
| 82 // Send a RTCP sender report. |
| 83 // |current_time| is the current time reported by a tick clock. |
| 84 // |current_time_as_rtp_timestamp| is the corresponding RTP timestamp. |
| 85 void SendRtcpFromRtpSender(base::TimeTicks current_time, |
| 86 uint32 current_time_as_rtp_timestamp); |
| 82 | 87 |
| 83 // |cast_message| and |rtcp_events| is optional; if |cast_message| is | 88 // |cast_message| and |rtcp_events| is optional; if |cast_message| is |
| 84 // provided the RTCP receiver report will append a Cast message containing | 89 // provided the RTCP receiver report will append a Cast message containing |
| 85 // Acks and Nacks; if |rtcp_events| is provided the RTCP receiver report | 90 // Acks and Nacks; if |rtcp_events| is provided the RTCP receiver report |
| 86 // will append the log messages. | 91 // will append the log messages. |
| 87 void SendRtcpFromRtpReceiver( | 92 void SendRtcpFromRtpReceiver( |
| 88 const RtcpCastMessage* cast_message, | 93 const RtcpCastMessage* cast_message, |
| 89 const ReceiverRtcpEventSubscriber::RtcpEventMultiMap* rtcp_events); | 94 const ReceiverRtcpEventSubscriber::RtcpEventMultiMap* rtcp_events); |
| 90 | 95 |
| 91 void IncomingRtcpPacket(const uint8* rtcp_buffer, size_t length); | 96 void IncomingRtcpPacket(const uint8* rtcp_buffer, size_t length); |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 uint16 target_delay_ms_; | 178 uint16 target_delay_ms_; |
| 174 bool is_audio_; | 179 bool is_audio_; |
| 175 | 180 |
| 176 DISALLOW_COPY_AND_ASSIGN(Rtcp); | 181 DISALLOW_COPY_AND_ASSIGN(Rtcp); |
| 177 }; | 182 }; |
| 178 | 183 |
| 179 } // namespace cast | 184 } // namespace cast |
| 180 } // namespace media | 185 } // namespace media |
| 181 | 186 |
| 182 #endif // MEDIA_CAST_RTCP_RTCP_H_ | 187 #endif // MEDIA_CAST_RTCP_RTCP_H_ |
| OLD | NEW |