Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1382)

Side by Side Diff: webrtc/video/rtp_stream_receiver.h

Issue 2704183002: Revert of Revert Make the new jitter buffer the default jitter buffer. (Closed)
Patch Set: Rebase Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « webrtc/video/receive_statistics_proxy_unittest.cc ('k') | webrtc/video/rtp_stream_receiver.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 58
59 class RtpStreamReceiver : public RtpData, 59 class RtpStreamReceiver : public RtpData,
60 public RtpFeedback, 60 public RtpFeedback,
61 public VCMFrameTypeCallback, 61 public VCMFrameTypeCallback,
62 public VCMPacketRequestCallback, 62 public VCMPacketRequestCallback,
63 public video_coding::OnReceivedFrameCallback, 63 public video_coding::OnReceivedFrameCallback,
64 public video_coding::OnCompleteFrameCallback, 64 public video_coding::OnCompleteFrameCallback,
65 public CallStatsObserver { 65 public CallStatsObserver {
66 public: 66 public:
67 RtpStreamReceiver( 67 RtpStreamReceiver(
68 vcm::VideoReceiver* video_receiver,
69 Transport* transport, 68 Transport* transport,
70 RtcpRttStats* rtt_stats, 69 RtcpRttStats* rtt_stats,
71 PacketRouter* packet_router, 70 PacketRouter* packet_router,
72 VieRemb* remb, 71 VieRemb* remb,
73 const VideoReceiveStream::Config* config, 72 const VideoReceiveStream::Config* config,
74 ReceiveStatisticsProxy* receive_stats_proxy, 73 ReceiveStatisticsProxy* receive_stats_proxy,
75 ProcessThread* process_thread, 74 ProcessThread* process_thread,
76 NackSender* nack_sender, 75 NackSender* nack_sender,
77 KeyFrameRequestSender* keyframe_request_sender, 76 KeyFrameRequestSender* keyframe_request_sender,
78 video_coding::OnCompleteFrameCallback* complete_frame_callback, 77 video_coding::OnCompleteFrameCallback* complete_frame_callback,
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 bool IsPacketInOrder(const RTPHeader& header) const; 153 bool IsPacketInOrder(const RTPHeader& header) const;
155 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const; 154 bool IsPacketRetransmitted(const RTPHeader& header, bool in_order) const;
156 void UpdateHistograms(); 155 void UpdateHistograms();
157 void EnableReceiveRtpHeaderExtension(const std::string& extension, int id); 156 void EnableReceiveRtpHeaderExtension(const std::string& extension, int id);
158 bool IsRedEnabled() const; 157 bool IsRedEnabled() const;
159 void InsertSpsPpsIntoTracker(uint8_t payload_type); 158 void InsertSpsPpsIntoTracker(uint8_t payload_type);
160 159
161 Clock* const clock_; 160 Clock* const clock_;
162 // Ownership of this object lies with VideoReceiveStream, which owns |this|. 161 // Ownership of this object lies with VideoReceiveStream, which owns |this|.
163 const VideoReceiveStream::Config& config_; 162 const VideoReceiveStream::Config& config_;
164 vcm::VideoReceiver* const video_receiver_;
165 PacketRouter* const packet_router_; 163 PacketRouter* const packet_router_;
166 VieRemb* const remb_; 164 VieRemb* const remb_;
167 ProcessThread* const process_thread_; 165 ProcessThread* const process_thread_;
168 166
169 RemoteNtpTimeEstimator ntp_estimator_; 167 RemoteNtpTimeEstimator ntp_estimator_;
170 RTPPayloadRegistry rtp_payload_registry_; 168 RTPPayloadRegistry rtp_payload_registry_;
171 169
172 const std::unique_ptr<RtpHeaderParser> rtp_header_parser_; 170 const std::unique_ptr<RtpHeaderParser> rtp_header_parser_;
173 const std::unique_ptr<RtpReceiver> rtp_receiver_; 171 const std::unique_ptr<RtpReceiver> rtp_receiver_;
174 const std::unique_ptr<ReceiveStatistics> rtp_receive_statistics_; 172 const std::unique_ptr<ReceiveStatistics> rtp_receive_statistics_;
175 std::unique_ptr<UlpfecReceiver> ulpfec_receiver_; 173 std::unique_ptr<UlpfecReceiver> ulpfec_receiver_;
176 174
177 rtc::CriticalSection receive_cs_; 175 rtc::CriticalSection receive_cs_;
178 bool receiving_ GUARDED_BY(receive_cs_); 176 bool receiving_ GUARDED_BY(receive_cs_);
179 uint8_t restored_packet_[IP_PACKET_SIZE] GUARDED_BY(receive_cs_); 177 uint8_t restored_packet_[IP_PACKET_SIZE] GUARDED_BY(receive_cs_);
180 bool restored_packet_in_use_ GUARDED_BY(receive_cs_); 178 bool restored_packet_in_use_ GUARDED_BY(receive_cs_);
181 int64_t last_packet_log_ms_ GUARDED_BY(receive_cs_); 179 int64_t last_packet_log_ms_ GUARDED_BY(receive_cs_);
182 180
183 const std::unique_ptr<RtpRtcp> rtp_rtcp_; 181 const std::unique_ptr<RtpRtcp> rtp_rtcp_;
184 182
185 // Members for the new jitter buffer experiment. 183 // Members for the new jitter buffer experiment.
186 bool jitter_buffer_experiment_;
187 video_coding::OnCompleteFrameCallback* complete_frame_callback_; 184 video_coding::OnCompleteFrameCallback* complete_frame_callback_;
188 KeyFrameRequestSender* keyframe_request_sender_; 185 KeyFrameRequestSender* keyframe_request_sender_;
189 VCMTiming* timing_; 186 VCMTiming* timing_;
190 std::unique_ptr<NackModule> nack_module_; 187 std::unique_ptr<NackModule> nack_module_;
191 rtc::scoped_refptr<video_coding::PacketBuffer> packet_buffer_; 188 rtc::scoped_refptr<video_coding::PacketBuffer> packet_buffer_;
192 std::unique_ptr<video_coding::RtpFrameReferenceFinder> reference_finder_; 189 std::unique_ptr<video_coding::RtpFrameReferenceFinder> reference_finder_;
193 rtc::CriticalSection last_seq_num_cs_; 190 rtc::CriticalSection last_seq_num_cs_;
194 std::map<uint16_t, uint16_t, DescendingSeqNumComp<uint16_t>> 191 std::map<uint16_t, uint16_t, DescendingSeqNumComp<uint16_t>>
195 last_seq_num_for_pic_id_ GUARDED_BY(last_seq_num_cs_); 192 last_seq_num_for_pic_id_ GUARDED_BY(last_seq_num_cs_);
196 video_coding::H264SpsPpsTracker tracker_; 193 video_coding::H264SpsPpsTracker tracker_;
197 // TODO(johan): Remove pt_codec_params_ once 194 // TODO(johan): Remove pt_codec_params_ once
198 // https://bugs.chromium.org/p/webrtc/issues/detail?id=6883 is resolved. 195 // https://bugs.chromium.org/p/webrtc/issues/detail?id=6883 is resolved.
199 // Maps a payload type to a map of out-of-band supplied codec parameters. 196 // Maps a payload type to a map of out-of-band supplied codec parameters.
200 std::map<uint8_t, std::map<std::string, std::string>> pt_codec_params_; 197 std::map<uint8_t, std::map<std::string, std::string>> pt_codec_params_;
201 int16_t last_payload_type_ = -1; 198 int16_t last_payload_type_ = -1;
202 }; 199 };
203 200
204 } // namespace webrtc 201 } // namespace webrtc
205 202
206 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_ 203 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_
OLDNEW
« no previous file with comments | « webrtc/video/receive_statistics_proxy_unittest.cc ('k') | webrtc/video/rtp_stream_receiver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698