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

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

Issue 2011433002: Properly wire up the event log to the VideoSendStream. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 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/video_send_stream.h ('k') | no next file » | 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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 std::vector<RtpRtcp*> CreateRtpRtcpModules( 42 std::vector<RtpRtcp*> CreateRtpRtcpModules(
43 Transport* outgoing_transport, 43 Transport* outgoing_transport,
44 RtcpIntraFrameObserver* intra_frame_callback, 44 RtcpIntraFrameObserver* intra_frame_callback,
45 RtcpBandwidthObserver* bandwidth_callback, 45 RtcpBandwidthObserver* bandwidth_callback,
46 TransportFeedbackObserver* transport_feedback_callback, 46 TransportFeedbackObserver* transport_feedback_callback,
47 RtcpRttStats* rtt_stats, 47 RtcpRttStats* rtt_stats,
48 RtpPacketSender* paced_sender, 48 RtpPacketSender* paced_sender,
49 TransportSequenceNumberAllocator* transport_sequence_number_allocator, 49 TransportSequenceNumberAllocator* transport_sequence_number_allocator,
50 SendStatisticsProxy* stats_proxy, 50 SendStatisticsProxy* stats_proxy,
51 SendDelayStats* send_delay_stats, 51 SendDelayStats* send_delay_stats,
52 RtcEventLog* event_log,
52 size_t num_modules) { 53 size_t num_modules) {
53 RTC_DCHECK_GT(num_modules, 0u); 54 RTC_DCHECK_GT(num_modules, 0u);
54 RtpRtcp::Configuration configuration; 55 RtpRtcp::Configuration configuration;
55 ReceiveStatistics* null_receive_statistics = configuration.receive_statistics; 56 ReceiveStatistics* null_receive_statistics = configuration.receive_statistics;
56 configuration.audio = false; 57 configuration.audio = false;
57 configuration.receiver_only = false; 58 configuration.receiver_only = false;
58 configuration.receive_statistics = null_receive_statistics; 59 configuration.receive_statistics = null_receive_statistics;
59 configuration.outgoing_transport = outgoing_transport; 60 configuration.outgoing_transport = outgoing_transport;
60 configuration.intra_frame_callback = intra_frame_callback; 61 configuration.intra_frame_callback = intra_frame_callback;
62 configuration.bandwidth_callback = bandwidth_callback;
63 configuration.transport_feedback_callback = transport_feedback_callback;
61 configuration.rtt_stats = rtt_stats; 64 configuration.rtt_stats = rtt_stats;
62 configuration.rtcp_packet_type_counter_observer = stats_proxy; 65 configuration.rtcp_packet_type_counter_observer = stats_proxy;
63 configuration.paced_sender = paced_sender; 66 configuration.paced_sender = paced_sender;
64 configuration.transport_sequence_number_allocator = 67 configuration.transport_sequence_number_allocator =
65 transport_sequence_number_allocator; 68 transport_sequence_number_allocator;
66 configuration.send_bitrate_observer = stats_proxy; 69 configuration.send_bitrate_observer = stats_proxy;
67 configuration.send_frame_count_observer = stats_proxy; 70 configuration.send_frame_count_observer = stats_proxy;
68 configuration.send_side_delay_observer = stats_proxy; 71 configuration.send_side_delay_observer = stats_proxy;
69 configuration.send_packet_observer = send_delay_stats; 72 configuration.send_packet_observer = send_delay_stats;
70 configuration.bandwidth_callback = bandwidth_callback; 73 configuration.event_log = event_log;
71 configuration.transport_feedback_callback = transport_feedback_callback;
72 74
73 std::vector<RtpRtcp*> modules; 75 std::vector<RtpRtcp*> modules;
74 for (size_t i = 0; i < num_modules; ++i) { 76 for (size_t i = 0; i < num_modules; ++i) {
75 RtpRtcp* rtp_rtcp = RtpRtcp::CreateRtpRtcp(configuration); 77 RtpRtcp* rtp_rtcp = RtpRtcp::CreateRtpRtcp(configuration);
76 rtp_rtcp->SetSendingStatus(false); 78 rtp_rtcp->SetSendingStatus(false);
77 rtp_rtcp->SetSendingMediaStatus(false); 79 rtp_rtcp->SetSendingMediaStatus(false);
78 rtp_rtcp->SetRTCPStatus(RtcpMode::kCompound); 80 rtp_rtcp->SetRTCPStatus(RtcpMode::kCompound);
79 modules.push_back(rtp_rtcp); 81 modules.push_back(rtp_rtcp);
80 } 82 }
81 return modules; 83 return modules;
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
346 348
347 namespace internal { 349 namespace internal {
348 VideoSendStream::VideoSendStream( 350 VideoSendStream::VideoSendStream(
349 int num_cpu_cores, 351 int num_cpu_cores,
350 ProcessThread* module_process_thread, 352 ProcessThread* module_process_thread,
351 CallStats* call_stats, 353 CallStats* call_stats,
352 CongestionController* congestion_controller, 354 CongestionController* congestion_controller,
353 BitrateAllocator* bitrate_allocator, 355 BitrateAllocator* bitrate_allocator,
354 SendDelayStats* send_delay_stats, 356 SendDelayStats* send_delay_stats,
355 VieRemb* remb, 357 VieRemb* remb,
358 RtcEventLog* event_log,
356 const VideoSendStream::Config& config, 359 const VideoSendStream::Config& config,
357 const VideoEncoderConfig& encoder_config, 360 const VideoEncoderConfig& encoder_config,
358 const std::map<uint32_t, RtpState>& suspended_ssrcs) 361 const std::map<uint32_t, RtpState>& suspended_ssrcs)
359 : stats_proxy_(Clock::GetRealTimeClock(), 362 : stats_proxy_(Clock::GetRealTimeClock(),
360 config, 363 config,
361 encoder_config.content_type), 364 encoder_config.content_type),
362 encoded_frame_proxy_(config.post_encode_callback), 365 encoded_frame_proxy_(config.post_encode_callback),
363 config_(config), 366 config_(config),
364 suspended_ssrcs_(suspended_ssrcs), 367 suspended_ssrcs_(suspended_ssrcs),
365 module_process_thread_(module_process_thread), 368 module_process_thread_(module_process_thread),
(...skipping 24 matching lines...) Expand all
390 rtp_rtcp_modules_(CreateRtpRtcpModules( 393 rtp_rtcp_modules_(CreateRtpRtcpModules(
391 config.send_transport, 394 config.send_transport,
392 &encoder_feedback_, 395 &encoder_feedback_,
393 bandwidth_observer_.get(), 396 bandwidth_observer_.get(),
394 congestion_controller_->GetTransportFeedbackObserver(), 397 congestion_controller_->GetTransportFeedbackObserver(),
395 call_stats_->rtcp_rtt_stats(), 398 call_stats_->rtcp_rtt_stats(),
396 congestion_controller_->pacer(), 399 congestion_controller_->pacer(),
397 congestion_controller_->packet_router(), 400 congestion_controller_->packet_router(),
398 &stats_proxy_, 401 &stats_proxy_,
399 send_delay_stats, 402 send_delay_stats,
403 event_log,
400 config_.rtp.ssrcs.size())), 404 config_.rtp.ssrcs.size())),
401 payload_router_(rtp_rtcp_modules_, config.encoder_settings.payload_type), 405 payload_router_(rtp_rtcp_modules_, config.encoder_settings.payload_type),
402 input_(&encoder_wakeup_event_, 406 input_(&encoder_wakeup_event_,
403 config_.local_renderer, 407 config_.local_renderer,
404 &stats_proxy_, 408 &stats_proxy_,
405 &overuse_detector_) { 409 &overuse_detector_) {
406 LOG(LS_INFO) << "VideoSendStream: " << config_.ToString(); 410 LOG(LS_INFO) << "VideoSendStream: " << config_.ToString();
407 411
408 RTC_DCHECK(!config_.rtp.ssrcs.empty()); 412 RTC_DCHECK(!config_.rtp.ssrcs.empty());
409 RTC_DCHECK(module_process_thread_); 413 RTC_DCHECK(module_process_thread_);
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
802 &module_nack_rate); 806 &module_nack_rate);
803 *sent_video_rate_bps += module_video_rate; 807 *sent_video_rate_bps += module_video_rate;
804 *sent_nack_rate_bps += module_nack_rate; 808 *sent_nack_rate_bps += module_nack_rate;
805 *sent_fec_rate_bps += module_fec_rate; 809 *sent_fec_rate_bps += module_fec_rate;
806 } 810 }
807 return 0; 811 return 0;
808 } 812 }
809 813
810 } // namespace internal 814 } // namespace internal
811 } // namespace webrtc 815 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/video_send_stream.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698