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

Side by Side Diff: webrtc/modules/desktop_capture/screen_capturer_differ_wrapper.cc

Issue 2409833002: Remove DesktopRegion parameter in DesktopCapturer::Capture. (Closed)
Patch Set: Change Capture2 to CaptureFrame Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 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 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 void ScreenCapturerDifferWrapper::Start(DesktopCapturer::Callback* callback) { 154 void ScreenCapturerDifferWrapper::Start(DesktopCapturer::Callback* callback) {
155 callback_ = callback; 155 callback_ = callback;
156 base_capturer_->Start(this); 156 base_capturer_->Start(this);
157 } 157 }
158 158
159 void ScreenCapturerDifferWrapper::SetSharedMemoryFactory( 159 void ScreenCapturerDifferWrapper::SetSharedMemoryFactory(
160 std::unique_ptr<SharedMemoryFactory> shared_memory_factory) { 160 std::unique_ptr<SharedMemoryFactory> shared_memory_factory) {
161 base_capturer_->SetSharedMemoryFactory(std::move(shared_memory_factory)); 161 base_capturer_->SetSharedMemoryFactory(std::move(shared_memory_factory));
162 } 162 }
163 163
164 void ScreenCapturerDifferWrapper::Capture(const DesktopRegion& region) { 164 void ScreenCapturerDifferWrapper::CaptureFrame() {
165 base_capturer_->Capture(region); 165 base_capturer_->CaptureFrame();
166 } 166 }
167 167
168 bool ScreenCapturerDifferWrapper::GetScreenList(ScreenList* screens) { 168 bool ScreenCapturerDifferWrapper::GetScreenList(ScreenList* screens) {
169 return base_capturer_->GetScreenList(screens); 169 return base_capturer_->GetScreenList(screens);
170 } 170 }
171 171
172 bool ScreenCapturerDifferWrapper::SelectScreen(ScreenId id) { 172 bool ScreenCapturerDifferWrapper::SelectScreen(ScreenId id) {
173 return base_capturer_->SelectScreen(id); 173 return base_capturer_->SelectScreen(id);
174 } 174 }
175 175
(...skipping 29 matching lines...) Expand all
205 } 205 }
206 last_frame_ = frame->Share(); 206 last_frame_ = frame->Share();
207 207
208 frame->set_capture_time_ms(frame->GetUnderlyingFrame()->capture_time_ms() + 208 frame->set_capture_time_ms(frame->GetUnderlyingFrame()->capture_time_ms() +
209 (rtc::TimeNanos() - start_time_nanos) / 209 (rtc::TimeNanos() - start_time_nanos) /
210 rtc::kNumNanosecsPerMillisec); 210 rtc::kNumNanosecsPerMillisec);
211 callback_->OnCaptureResult(result, std::move(frame)); 211 callback_->OnCaptureResult(result, std::move(frame));
212 } 212 }
213 213
214 } // namespace webrtc 214 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698