OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 |
11 #ifndef WEBRTC_VIDEO_VIE_RECEIVER_H_ | 11 #ifndef WEBRTC_VIDEO_VIE_RECEIVER_H_ |
12 #define WEBRTC_VIDEO_VIE_RECEIVER_H_ | 12 #define WEBRTC_VIDEO_VIE_RECEIVER_H_ |
13 | 13 |
14 #include <list> | 14 #include <list> |
15 #include <vector> | 15 #include <vector> |
16 | 16 |
17 #include "webrtc/base/scoped_ptr.h" | 17 #include "webrtc/base/scoped_ptr.h" |
| 18 #include "webrtc/base/criticalsection.h" |
18 #include "webrtc/engine_configurations.h" | 19 #include "webrtc/engine_configurations.h" |
19 #include "webrtc/modules/rtp_rtcp/include/receive_statistics.h" | 20 #include "webrtc/modules/rtp_rtcp/include/receive_statistics.h" |
20 #include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h" | 21 #include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h" |
21 #include "webrtc/typedefs.h" | 22 #include "webrtc/typedefs.h" |
22 | 23 |
23 namespace webrtc { | 24 namespace webrtc { |
24 | 25 |
25 class CriticalSectionWrapper; | |
26 class FecReceiver; | 26 class FecReceiver; |
27 class RemoteNtpTimeEstimator; | 27 class RemoteNtpTimeEstimator; |
28 class ReceiveStatistics; | 28 class ReceiveStatistics; |
29 class RemoteBitrateEstimator; | 29 class RemoteBitrateEstimator; |
30 class RtpHeaderParser; | 30 class RtpHeaderParser; |
31 class RTPPayloadRegistry; | 31 class RTPPayloadRegistry; |
32 class RtpReceiver; | 32 class RtpReceiver; |
33 class RtpRtcp; | 33 class RtpRtcp; |
34 class VideoCodingModule; | 34 class VideoCodingModule; |
35 struct ReceiveBandwidthEstimatorStats; | 35 struct ReceiveBandwidthEstimatorStats; |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 // This function assumes that it's being called from only one thread. | 97 // This function assumes that it's being called from only one thread. |
98 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet, | 98 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet, |
99 size_t packet_length, | 99 size_t packet_length, |
100 const RTPHeader& header); | 100 const RTPHeader& header); |
101 void NotifyReceiverOfFecPacket(const RTPHeader& header); | 101 void NotifyReceiverOfFecPacket(const RTPHeader& header); |
102 int InsertRTCPPacket(const uint8_t* rtcp_packet, size_t rtcp_packet_length); | 102 int InsertRTCPPacket(const uint8_t* rtcp_packet, size_t rtcp_packet_length); |
103 bool IsPacketInOrder(const RTPHeader& header) const; | 103 bool IsPacketInOrder(const RTPHeader& header) const; |
104 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const; | 104 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const; |
105 void UpdateHistograms(); | 105 void UpdateHistograms(); |
106 | 106 |
107 rtc::scoped_ptr<CriticalSectionWrapper> receive_cs_; | 107 rtc::CriticalSection receive_cs_; |
108 Clock* clock_; | 108 Clock* clock_; |
109 rtc::scoped_ptr<RtpHeaderParser> rtp_header_parser_; | 109 rtc::scoped_ptr<RtpHeaderParser> rtp_header_parser_; |
110 rtc::scoped_ptr<RTPPayloadRegistry> rtp_payload_registry_; | 110 rtc::scoped_ptr<RTPPayloadRegistry> rtp_payload_registry_; |
111 rtc::scoped_ptr<RtpReceiver> rtp_receiver_; | 111 rtc::scoped_ptr<RtpReceiver> rtp_receiver_; |
112 const rtc::scoped_ptr<ReceiveStatistics> rtp_receive_statistics_; | 112 const rtc::scoped_ptr<ReceiveStatistics> rtp_receive_statistics_; |
113 rtc::scoped_ptr<FecReceiver> fec_receiver_; | 113 rtc::scoped_ptr<FecReceiver> fec_receiver_; |
114 RtpRtcp* rtp_rtcp_; | 114 RtpRtcp* rtp_rtcp_; |
115 std::vector<RtpRtcp*> rtp_rtcp_simulcast_; | 115 std::vector<RtpRtcp*> rtp_rtcp_simulcast_; |
116 VideoCodingModule* vcm_; | 116 VideoCodingModule* vcm_; |
117 RemoteBitrateEstimator* remote_bitrate_estimator_; | 117 RemoteBitrateEstimator* remote_bitrate_estimator_; |
118 | 118 |
119 rtc::scoped_ptr<RemoteNtpTimeEstimator> ntp_estimator_; | 119 rtc::scoped_ptr<RemoteNtpTimeEstimator> ntp_estimator_; |
120 | 120 |
121 bool receiving_; | 121 bool receiving_; |
122 uint8_t restored_packet_[IP_PACKET_SIZE]; | 122 uint8_t restored_packet_[IP_PACKET_SIZE]; |
123 bool restored_packet_in_use_; | 123 bool restored_packet_in_use_; |
124 bool receiving_ast_enabled_; | 124 bool receiving_ast_enabled_; |
125 bool receiving_cvo_enabled_; | 125 bool receiving_cvo_enabled_; |
126 bool receiving_tsn_enabled_; | 126 bool receiving_tsn_enabled_; |
127 int64_t last_packet_log_ms_; | 127 int64_t last_packet_log_ms_; |
128 }; | 128 }; |
129 | 129 |
130 } // namespace webrtc | 130 } // namespace webrtc |
131 | 131 |
132 #endif // WEBRTC_VIDEO_VIE_RECEIVER_H_ | 132 #endif // WEBRTC_VIDEO_VIE_RECEIVER_H_ |
OLD | NEW |