OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "remoting/host/capturer_gdi.h" | 5 #include "remoting/host/capturer_gdi.h" |
6 #include "remoting/host/differ.h" | 6 #include "remoting/host/differ.h" |
7 | 7 |
8 #include "gfx/rect.h" | 8 #include "gfx/rect.h" |
9 | 9 |
10 namespace remoting { | 10 namespace remoting { |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 | 129 |
130 void CapturerGdi::CaptureImage() { | 130 void CapturerGdi::CaptureImage() { |
131 // Select the target bitmap into the memory dc. | 131 // Select the target bitmap into the memory dc. |
132 SelectObject(memory_dc_, target_bitmap_[current_buffer_]); | 132 SelectObject(memory_dc_, target_bitmap_[current_buffer_]); |
133 | 133 |
134 // And then copy the rect from desktop to memory. | 134 // And then copy the rect from desktop to memory. |
135 BitBlt(memory_dc_, 0, 0, width_, height_, desktop_dc_, 0, 0, | 135 BitBlt(memory_dc_, 0, 0, width_, height_, desktop_dc_, 0, 0, |
136 SRCCOPY | CAPTUREBLT); | 136 SRCCOPY | CAPTUREBLT); |
137 } | 137 } |
138 | 138 |
| 139 // static |
| 140 Capturer* Capturer::Create(MessageLoop* message_loop) { |
| 141 return new CapturerGdi(message_loop); |
| 142 } |
| 143 |
139 } // namespace remoting | 144 } // namespace remoting |
OLD | NEW |