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

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

Issue 2490063002: Remove ScreenCapturer and WindowCapturer (Closed)
Patch Set: Created 4 years, 1 month 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 16 matching lines...) Expand all
27 } 27 }
28 28
29 bool DesktopCapturer::SelectSource(SourceId id) { 29 bool DesktopCapturer::SelectSource(SourceId id) {
30 return false; 30 return false;
31 } 31 }
32 32
33 bool DesktopCapturer::FocusOnSelectedSource() { 33 bool DesktopCapturer::FocusOnSelectedSource() {
34 return false; 34 return false;
35 } 35 }
36 36
37 // Some platforms, such as ChromeOS, have their DesktopCapturer implementations
38 // in Chromium. So even we do not have CreateRawWindowCapturer() or
39 // CreateRawScreenCapturer() implemented in WebRTC, we still need to build other
40 // DesktopCapturer components when RTC_DESKTOP_CAPTURE_SUPPORTED is not defined.
41 #if defined(RTC_DESKTOP_CAPTURE_SUPPORTED)
42 // static 37 // static
43 std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateWindowCapturer( 38 std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateWindowCapturer(
44 const DesktopCaptureOptions& options) { 39 const DesktopCaptureOptions& options) {
45 std::unique_ptr<DesktopCapturer> capturer = CreateRawWindowCapturer(options); 40 std::unique_ptr<DesktopCapturer> capturer = CreateRawWindowCapturer(options);
46 if (options.detect_updated_region()) { 41 if (options.detect_updated_region()) {
47 capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer))); 42 capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
48 } 43 }
49 44
50 return capturer; 45 return capturer;
51 } 46 }
52 47
53 // static 48 // static
54 std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateScreenCapturer( 49 std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateScreenCapturer(
55 const DesktopCaptureOptions& options) { 50 const DesktopCaptureOptions& options) {
56 std::unique_ptr<DesktopCapturer> capturer = CreateRawScreenCapturer(options); 51 std::unique_ptr<DesktopCapturer> capturer = CreateRawScreenCapturer(options);
57 if (options.detect_updated_region()) { 52 if (options.detect_updated_region()) {
58 capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer))); 53 capturer.reset(new DesktopCapturerDifferWrapper(std::move(capturer)));
59 } 54 }
60 55
61 return capturer; 56 return capturer;
62 } 57 }
63 #endif // defined(RTC_DESKTOP_CAPTURE_SUPPORTED)
64 58
65 } // namespace webrtc 59 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698