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

Side by Side Diff: webrtc/video/video_receive_stream.cc

Issue 2678343002: Delete VideoReceiveStream::Config::pre_render_callback. (Closed)
Patch Set: Rebased. 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/end_to_end_tests.cc ('k') | webrtc/video/video_send_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) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 ss << ", "; 60 ss << ", ";
61 } 61 }
62 ss << ']'; 62 ss << ']';
63 ss << ", rtp: " << rtp.ToString(); 63 ss << ", rtp: " << rtp.ToString();
64 ss << ", renderer: " << (renderer ? "(renderer)" : "nullptr"); 64 ss << ", renderer: " << (renderer ? "(renderer)" : "nullptr");
65 ss << ", render_delay_ms: " << render_delay_ms; 65 ss << ", render_delay_ms: " << render_delay_ms;
66 if (!sync_group.empty()) 66 if (!sync_group.empty())
67 ss << ", sync_group: " << sync_group; 67 ss << ", sync_group: " << sync_group;
68 ss << ", pre_decode_callback: " 68 ss << ", pre_decode_callback: "
69 << (pre_decode_callback ? "(EncodedFrameObserver)" : "nullptr"); 69 << (pre_decode_callback ? "(EncodedFrameObserver)" : "nullptr");
70 ss << ", pre_render_callback: "
71 << (pre_render_callback ? "(I420FrameCallback)" : "nullptr");
72 ss << ", target_delay_ms: " << target_delay_ms; 70 ss << ", target_delay_ms: " << target_delay_ms;
73 ss << '}'; 71 ss << '}';
74 72
75 return ss.str(); 73 return ss.str();
76 } 74 }
77 75
78 std::string VideoReceiveStream::Config::Rtp::ToString() const { 76 std::string VideoReceiveStream::Config::Rtp::ToString() const {
79 std::stringstream ss; 77 std::stringstream ss;
80 ss << "{remote_ssrc: " << remote_ssrc; 78 ss << "{remote_ssrc: " << remote_ssrc;
81 ss << ", local_ssrc: " << local_ssrc; 79 ss << ", local_ssrc: " << local_ssrc;
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 VideoCodec codec = CreateDecoderVideoCodec(decoder); 300 VideoCodec codec = CreateDecoderVideoCodec(decoder);
303 RTC_CHECK( 301 RTC_CHECK(
304 rtp_stream_receiver_.AddReceiveCodec(codec, decoder.codec_params)); 302 rtp_stream_receiver_.AddReceiveCodec(codec, decoder.codec_params));
305 RTC_CHECK_EQ(VCM_OK, video_receiver_.RegisterReceiveCodec( 303 RTC_CHECK_EQ(VCM_OK, video_receiver_.RegisterReceiveCodec(
306 &codec, num_cpu_cores_, false)); 304 &codec, num_cpu_cores_, false));
307 } 305 }
308 306
309 video_stream_decoder_.reset(new VideoStreamDecoder( 307 video_stream_decoder_.reset(new VideoStreamDecoder(
310 &video_receiver_, &rtp_stream_receiver_, &rtp_stream_receiver_, 308 &video_receiver_, &rtp_stream_receiver_, &rtp_stream_receiver_,
311 rtp_stream_receiver_.IsRetransmissionsEnabled(), protected_by_fec, 309 rtp_stream_receiver_.IsRetransmissionsEnabled(), protected_by_fec,
312 &stats_proxy_, renderer, config_.pre_render_callback)); 310 &stats_proxy_, renderer));
313 // Register the channel to receive stats updates. 311 // Register the channel to receive stats updates.
314 call_stats_->RegisterStatsObserver(video_stream_decoder_.get()); 312 call_stats_->RegisterStatsObserver(video_stream_decoder_.get());
315 // Start the decode thread 313 // Start the decode thread
316 decode_thread_.Start(); 314 decode_thread_.Start();
317 decode_thread_.SetPriority(rtc::kHighestPriority); 315 decode_thread_.SetPriority(rtc::kHighestPriority);
318 rtp_stream_receiver_.StartReceive(); 316 rtp_stream_receiver_.StartReceive();
319 } 317 }
320 318
321 void VideoReceiveStream::Stop() { 319 void VideoReceiveStream::Stop() {
322 RTC_DCHECK_RUN_ON(&worker_thread_checker_); 320 RTC_DCHECK_RUN_ON(&worker_thread_checker_);
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 if (video_receiver_.Decode(frame.get()) == VCM_OK) 487 if (video_receiver_.Decode(frame.get()) == VCM_OK)
490 rtp_stream_receiver_.FrameDecoded(frame->picture_id); 488 rtp_stream_receiver_.FrameDecoded(frame->picture_id);
491 } else { 489 } else {
492 LOG(LS_WARNING) << "No decodable frame in " << kMaxWaitForFrameMs 490 LOG(LS_WARNING) << "No decodable frame in " << kMaxWaitForFrameMs
493 << " ms, requesting keyframe."; 491 << " ms, requesting keyframe.";
494 RequestKeyFrame(); 492 RequestKeyFrame();
495 } 493 }
496 } 494 }
497 } // namespace internal 495 } // namespace internal
498 } // namespace webrtc 496 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/end_to_end_tests.cc ('k') | webrtc/video/video_send_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698