Chromium Code Reviews| Index: webrtc/video/video_send_stream.cc |
| diff --git a/webrtc/video/video_send_stream.cc b/webrtc/video/video_send_stream.cc |
| index b98a1f86f85814b80764ad81da508a90c4ed71cc..3cf599fe9b99a1d4fcb9b0d755c6ce2a181fd7f8 100644 |
| --- a/webrtc/video/video_send_stream.cc |
| +++ b/webrtc/video/video_send_stream.cc |
| @@ -101,7 +101,6 @@ std::string VideoSendStream::Config::ToString() const { |
| namespace internal { |
| VideoSendStream::VideoSendStream( |
| - CpuOveruseObserver* overuse_observer, |
| int num_cpu_cores, |
| ProcessThread* module_process_thread, |
| ChannelGroup* channel_group, |
| @@ -162,7 +161,7 @@ VideoSendStream::VideoSendStream( |
| input_.reset(new internal::VideoCaptureInput( |
| module_process_thread_, vie_encoder_, config_.local_renderer, |
| - &stats_proxy_, overuse_observer)); |
| + &stats_proxy_, this)); |
| // 28 to match packet overhead in ModuleRtpRtcpImpl. |
| DCHECK_LE(config_.rtp.max_packet_size, static_cast<size_t>(0xFFFF - 28)); |
| @@ -390,6 +389,18 @@ VideoSendStream::Stats VideoSendStream::GetStats() { |
| return stats_proxy_.GetStats(); |
| } |
| +void VideoSendStream::OveruseDetected() { |
| + if (config_.overuse_callback) { |
|
pbos-webrtc
2015/09/03 20:44:55
Remove {}s for consistency outside of talk/.
the sun
2015/09/03 20:54:55
lol
pthatcher1
2015/09/04 04:56:03
Please keep {}s to be consistent with code inside
|
| + config_.overuse_callback->OnLoadUpdate(LoadObserver::kOveruse); |
| + } |
| +} |
| + |
| +void VideoSendStream::NormalUsage() { |
| + if (config_.overuse_callback) { |
|
pbos-webrtc
2015/09/03 20:44:55
Remove {}s for consistency outside of talk/.
the sun
2015/09/03 20:54:55
lol
pthatcher1
2015/09/04 04:56:03
Please keep {}s to be consistent with code inside
|
| + config_.overuse_callback->OnLoadUpdate(LoadObserver::kUnderuse); |
| + } |
| +} |
| + |
| void VideoSendStream::ConfigureSsrcs() { |
| vie_channel_->SetSSRC(config_.rtp.ssrcs.front(), kViEStreamTypeNormal, 0); |
| for (size_t i = 0; i < config_.rtp.ssrcs.size(); ++i) { |