| 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 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 public VCMFrameTypeCallback, | 53 public VCMFrameTypeCallback, |
| 54 public VCMPacketRequestCallback { | 54 public VCMPacketRequestCallback { |
| 55 public: | 55 public: |
| 56 RtpStreamReceiver(vcm::VideoReceiver* video_receiver, | 56 RtpStreamReceiver(vcm::VideoReceiver* video_receiver, |
| 57 RemoteBitrateEstimator* remote_bitrate_estimator, | 57 RemoteBitrateEstimator* remote_bitrate_estimator, |
| 58 Transport* transport, | 58 Transport* transport, |
| 59 RtcpRttStats* rtt_stats, | 59 RtcpRttStats* rtt_stats, |
| 60 PacedSender* paced_sender, | 60 PacedSender* paced_sender, |
| 61 PacketRouter* packet_router, | 61 PacketRouter* packet_router, |
| 62 VieRemb* remb, | 62 VieRemb* remb, |
| 63 const VideoReceiveStream::Config& config, | 63 const VideoReceiveStream::Config* config, |
| 64 ReceiveStatisticsProxy* receive_stats_proxy, | 64 ReceiveStatisticsProxy* receive_stats_proxy, |
| 65 ProcessThread* process_thread); | 65 ProcessThread* process_thread); |
| 66 ~RtpStreamReceiver(); | 66 ~RtpStreamReceiver(); |
| 67 | 67 |
| 68 bool SetReceiveCodec(const VideoCodec& video_codec); | 68 bool SetReceiveCodec(const VideoCodec& video_codec); |
| 69 | 69 |
| 70 uint32_t GetRemoteSsrc() const; | 70 uint32_t GetRemoteSsrc() const; |
| 71 int GetCsrcs(uint32_t* csrcs) const; | 71 int GetCsrcs(uint32_t* csrcs) const; |
| 72 | 72 |
| 73 RtpReceiver* GetRtpReceiver() const; | 73 RtpReceiver* GetRtpReceiver() const; |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet, | 121 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet, |
| 122 size_t packet_length, | 122 size_t packet_length, |
| 123 const RTPHeader& header); | 123 const RTPHeader& header); |
| 124 void NotifyReceiverOfFecPacket(const RTPHeader& header); | 124 void NotifyReceiverOfFecPacket(const RTPHeader& header); |
| 125 bool IsPacketInOrder(const RTPHeader& header) const; | 125 bool IsPacketInOrder(const RTPHeader& header) const; |
| 126 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const; | 126 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const; |
| 127 void UpdateHistograms(); | 127 void UpdateHistograms(); |
| 128 void EnableReceiveRtpHeaderExtension(const std::string& extension, int id); | 128 void EnableReceiveRtpHeaderExtension(const std::string& extension, int id); |
| 129 | 129 |
| 130 Clock* const clock_; | 130 Clock* const clock_; |
| 131 const VideoReceiveStream::Config config_; | 131 // Ownership of this object lies with VideoReceiveStream, which owns |this|. |
| 132 const VideoReceiveStream::Config& config_; |
| 132 vcm::VideoReceiver* const video_receiver_; | 133 vcm::VideoReceiver* const video_receiver_; |
| 133 RemoteBitrateEstimator* const remote_bitrate_estimator_; | 134 RemoteBitrateEstimator* const remote_bitrate_estimator_; |
| 134 PacketRouter* const packet_router_; | 135 PacketRouter* const packet_router_; |
| 135 VieRemb* const remb_; | 136 VieRemb* const remb_; |
| 136 ProcessThread* const process_thread_; | 137 ProcessThread* const process_thread_; |
| 137 | 138 |
| 138 RemoteNtpTimeEstimator ntp_estimator_; | 139 RemoteNtpTimeEstimator ntp_estimator_; |
| 139 RTPPayloadRegistry rtp_payload_registry_; | 140 RTPPayloadRegistry rtp_payload_registry_; |
| 140 | 141 |
| 141 const std::unique_ptr<RtpHeaderParser> rtp_header_parser_; | 142 const std::unique_ptr<RtpHeaderParser> rtp_header_parser_; |
| 142 const std::unique_ptr<RtpReceiver> rtp_receiver_; | 143 const std::unique_ptr<RtpReceiver> rtp_receiver_; |
| 143 const std::unique_ptr<ReceiveStatistics> rtp_receive_statistics_; | 144 const std::unique_ptr<ReceiveStatistics> rtp_receive_statistics_; |
| 144 std::unique_ptr<FecReceiver> fec_receiver_; | 145 std::unique_ptr<FecReceiver> fec_receiver_; |
| 145 | 146 |
| 146 rtc::CriticalSection receive_cs_; | 147 rtc::CriticalSection receive_cs_; |
| 147 bool receiving_ GUARDED_BY(receive_cs_); | 148 bool receiving_ GUARDED_BY(receive_cs_); |
| 148 uint8_t restored_packet_[IP_PACKET_SIZE] GUARDED_BY(receive_cs_); | 149 uint8_t restored_packet_[IP_PACKET_SIZE] GUARDED_BY(receive_cs_); |
| 149 bool restored_packet_in_use_ GUARDED_BY(receive_cs_); | 150 bool restored_packet_in_use_ GUARDED_BY(receive_cs_); |
| 150 int64_t last_packet_log_ms_ GUARDED_BY(receive_cs_); | 151 int64_t last_packet_log_ms_ GUARDED_BY(receive_cs_); |
| 151 | 152 |
| 152 const std::unique_ptr<RtpRtcp> rtp_rtcp_; | 153 const std::unique_ptr<RtpRtcp> rtp_rtcp_; |
| 153 }; | 154 }; |
| 154 | 155 |
| 155 } // namespace webrtc | 156 } // namespace webrtc |
| 156 | 157 |
| 157 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_ | 158 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_ |
| OLD | NEW |