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

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

Issue 2649873005: Call RtpStreamReceiver.AddReceiveCodec() with codec_params. (Closed)
Patch Set: Call RtpStreamReceiver.AddReceiveCodec() with codec_params. Created 3 years, 11 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 | « no previous file | webrtc/video/video_receive_stream.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 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 ReceiveStatisticsProxy* receive_stats_proxy, 75 ReceiveStatisticsProxy* receive_stats_proxy,
76 ProcessThread* process_thread, 76 ProcessThread* process_thread,
77 NackSender* nack_sender, 77 NackSender* nack_sender,
78 KeyFrameRequestSender* keyframe_request_sender, 78 KeyFrameRequestSender* keyframe_request_sender,
79 video_coding::OnCompleteFrameCallback* complete_frame_callback, 79 video_coding::OnCompleteFrameCallback* complete_frame_callback,
80 VCMTiming* timing); 80 VCMTiming* timing);
81 ~RtpStreamReceiver(); 81 ~RtpStreamReceiver();
82 82
83 bool AddReceiveCodec(const VideoCodec& video_codec, 83 bool AddReceiveCodec(const VideoCodec& video_codec,
84 const std::map<std::string, std::string>& codec_params); 84 const std::map<std::string, std::string>& codec_params);
85
86 bool AddReceiveCodec(const VideoCodec& video_codec);
87
88 uint32_t GetRemoteSsrc() const; 85 uint32_t GetRemoteSsrc() const;
89 int GetCsrcs(uint32_t* csrcs) const; 86 int GetCsrcs(uint32_t* csrcs) const;
90 87
91 RtpReceiver* GetRtpReceiver() const; 88 RtpReceiver* GetRtpReceiver() const;
92 RtpRtcp* rtp_rtcp() const { return rtp_rtcp_.get(); } 89 RtpRtcp* rtp_rtcp() const { return rtp_rtcp_.get(); }
93 90
94 void StartReceive(); 91 void StartReceive();
95 void StopReceive(); 92 void StopReceive();
96 93
97 bool DeliverRtp(const uint8_t* rtp_packet, 94 bool DeliverRtp(const uint8_t* rtp_packet,
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 void OnReceivedFrame( 134 void OnReceivedFrame(
138 std::unique_ptr<video_coding::RtpFrameObject> frame) override; 135 std::unique_ptr<video_coding::RtpFrameObject> frame) override;
139 136
140 // Implements OnCompleteFrameCallback. 137 // Implements OnCompleteFrameCallback.
141 void OnCompleteFrame( 138 void OnCompleteFrame(
142 std::unique_ptr<video_coding::FrameObject> frame) override; 139 std::unique_ptr<video_coding::FrameObject> frame) override;
143 140
144 void OnRttUpdate(int64_t avg_rtt_ms, int64_t max_rtt_ms) override; 141 void OnRttUpdate(int64_t avg_rtt_ms, int64_t max_rtt_ms) override;
145 142
146 private: 143 private:
144 bool AddReceiveCodec(const VideoCodec& video_codec);
147 bool ReceivePacket(const uint8_t* packet, 145 bool ReceivePacket(const uint8_t* packet,
148 size_t packet_length, 146 size_t packet_length,
149 const RTPHeader& header, 147 const RTPHeader& header,
150 bool in_order); 148 bool in_order);
151 // Parses and handles for instance RTX and RED headers. 149 // Parses and handles for instance RTX and RED headers.
152 // This function assumes that it's being called from only one thread. 150 // This function assumes that it's being called from only one thread.
153 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet, 151 bool ParseAndHandleEncapsulatingHeader(const uint8_t* packet,
154 size_t packet_length, 152 size_t packet_length,
155 const RTPHeader& header); 153 const RTPHeader& header);
156 void NotifyReceiverOfFecPacket(const RTPHeader& header); 154 void NotifyReceiverOfFecPacket(const RTPHeader& header);
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 // TODO(johan): Remove pt_codec_params_ once 199 // TODO(johan): Remove pt_codec_params_ once
202 // https://bugs.chromium.org/p/webrtc/issues/detail?id=6883 is resolved. 200 // https://bugs.chromium.org/p/webrtc/issues/detail?id=6883 is resolved.
203 // Maps a payload type to a map of out-of-band supplied codec parameters. 201 // Maps a payload type to a map of out-of-band supplied codec parameters.
204 std::map<uint8_t, std::map<std::string, std::string>> pt_codec_params_; 202 std::map<uint8_t, std::map<std::string, std::string>> pt_codec_params_;
205 int16_t last_payload_type_ = -1; 203 int16_t last_payload_type_ = -1;
206 }; 204 };
207 205
208 } // namespace webrtc 206 } // namespace webrtc
209 207
210 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_ 208 #endif // WEBRTC_VIDEO_RTP_STREAM_RECEIVER_H_
OLDNEW
« no previous file with comments | « no previous file | webrtc/video/video_receive_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698