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

Side by Side Diff: webrtc/video_engine/vie_encoder.cc

Issue 1398443007: Pause/resume pacer from Call instead of via SendStreams. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Remove call from vie encoder Created 5 years, 2 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_engine/vie_channel_group.cc ('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) 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 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 178
179 int ViEEncoder::Owner() const { 179 int ViEEncoder::Owner() const {
180 return channel_id_; 180 return channel_id_;
181 } 181 }
182 182
183 void ViEEncoder::SetNetworkTransmissionState(bool is_transmitting) { 183 void ViEEncoder::SetNetworkTransmissionState(bool is_transmitting) {
184 { 184 {
185 CriticalSectionScoped cs(data_cs_.get()); 185 CriticalSectionScoped cs(data_cs_.get());
186 network_is_transmitting_ = is_transmitting; 186 network_is_transmitting_ = is_transmitting;
187 } 187 }
188 if (is_transmitting) {
189 pacer_->Resume();
190 } else {
191 pacer_->Pause();
192 }
193 } 188 }
194 189
195 void ViEEncoder::Pause() { 190 void ViEEncoder::Pause() {
196 CriticalSectionScoped cs(data_cs_.get()); 191 CriticalSectionScoped cs(data_cs_.get());
197 encoder_paused_ = true; 192 encoder_paused_ = true;
198 } 193 }
199 194
200 void ViEEncoder::Restart() { 195 void ViEEncoder::Restart() {
201 CriticalSectionScoped cs(data_cs_.get()); 196 CriticalSectionScoped cs(data_cs_.get());
202 encoder_paused_ = false; 197 encoder_paused_ = false;
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after
723 const uint32_t width, 718 const uint32_t width,
724 const uint32_t height) { 719 const uint32_t height) {
725 return vpm_->SetTargetResolution(width, height, frame_rate); 720 return vpm_->SetTargetResolution(width, height, frame_rate);
726 } 721 }
727 722
728 void QMVideoSettingsCallback::SetTargetFramerate(int frame_rate) { 723 void QMVideoSettingsCallback::SetTargetFramerate(int frame_rate) {
729 vpm_->SetTargetFramerate(frame_rate); 724 vpm_->SetTargetFramerate(frame_rate);
730 } 725 }
731 726
732 } // namespace webrtc 727 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video_engine/vie_channel_group.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698