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

Unified Diff: webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc

Issue 2155813003: [Chromoting] Remove screen saver logic out of ScreenCapturer implementations (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc
diff --git a/webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc b/webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc
index 47d0134d4e12ce8e7972944431cf4b95a33db4d8..159e5a9195b516da17157a4e491b82b10afdff19 100644
--- a/webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc
+++ b/webrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc
@@ -452,7 +452,7 @@ bool ScreenCapturerWinDirectx::ForceDuplicateOutput() {
ScreenCapturerWinDirectx::ScreenCapturerWinDirectx(
const DesktopCaptureOptions& options)
- : callback_(nullptr), set_thread_execution_state_failed_(false) {
+ : callback_(nullptr) {
RTC_DCHECK(g_container && g_container->initialize_result);
// Texture instance won't change forever.
@@ -629,14 +629,6 @@ void ScreenCapturerWinDirectx::Capture(const DesktopRegion& region) {
RTC_DCHECK(g_container->duplication);
int64_t capture_start_time_nanos = rtc::TimeNanos();
- if (!SetThreadExecutionState(ES_DISPLAY_REQUIRED | ES_SYSTEM_REQUIRED)) {
- if (!set_thread_execution_state_failed_) {
- set_thread_execution_state_failed_ = true;
- LOG(LS_WARNING) << "Failed to make system & display power assertion: "
- << GetLastError();
- }
- }
-
DXGI_OUTDUPL_FRAME_INFO frame_info;
memset(&frame_info, 0, sizeof(DXGI_OUTDUPL_FRAME_INFO));
ComPtr<IDXGIResource> resource;

Powered by Google App Engine
This is Rietveld 408576698