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

Unified Diff: webrtc/modules/desktop_capture/screen_capturer_win.cc

Issue 2468753002: Add CreateWindowCapturer() and CreateScreenCapturer() in DesktopCapturer (Closed)
Patch Set: Build break without X11 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/desktop_capture/screen_capturer_win.cc
diff --git a/webrtc/modules/desktop_capture/screen_capturer_win.cc b/webrtc/modules/desktop_capture/screen_capturer_win.cc
index 1d05961affa9e2879894aa4b60e88522d407bc5b..00a512bdc7f72c1a46eed50df7d7f93eb0a05614 100644
--- a/webrtc/modules/desktop_capture/screen_capturer_win.cc
+++ b/webrtc/modules/desktop_capture/screen_capturer_win.cc
@@ -42,4 +42,22 @@ ScreenCapturer* ScreenCapturer::Create(const DesktopCaptureOptions& options) {
return capturer.release();
}
+// static
+std::unique_ptr<DesktopCapturer> DesktopCapturer::CreateRawScreenCapturer(
+ const DesktopCaptureOptions& options) {
+ std::unique_ptr<DesktopCapturer> capturer;
+ if (options.allow_directx_capturer() &&
+ ScreenCapturerWinDirectx::IsSupported()) {
+ capturer.reset(new ScreenCapturerWinDirectx(options));
+ } else {
+ capturer.reset(new ScreenCapturerWinGdi(options));
+ }
+
+ if (options.allow_use_magnification_api()) {
+ capturer.reset(new ScreenCapturerWinMagnifier(std::move(capturer)));
+ }
+
+ return capturer;
+}
+
} // namespace webrtc
« no previous file with comments | « webrtc/modules/desktop_capture/screen_capturer_null.cc ('k') | webrtc/modules/desktop_capture/screen_capturer_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698