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 #ifndef REMOTING_HOST_CAPTURER_MAC_H_ | 5 #ifndef REMOTING_HOST_CAPTURER_MAC_H_ |
6 #define REMOTING_HOST_CAPTURER_MAC_H_ | 6 #define REMOTING_HOST_CAPTURER_MAC_H_ |
7 | 7 |
8 #include "remoting/host/capturer.h" | 8 #include "remoting/host/capturer.h" |
9 #include <ApplicationServices/ApplicationServices.h> | 9 #include <ApplicationServices/ApplicationServices.h> |
10 #include <OpenGL/OpenGL.h> | 10 #include <OpenGL/OpenGL.h> |
11 #include "base/scoped_ptr.h" | 11 #include "base/scoped_ptr.h" |
12 | 12 |
13 namespace remoting { | 13 namespace remoting { |
14 | 14 |
15 // A class to perform capturing for mac. | 15 // A class to perform capturing for mac. |
16 class CapturerMac : public Capturer { | 16 class CapturerMac : public Capturer { |
17 public: | 17 public: |
18 CapturerMac(); | 18 CapturerMac(MessageLoop* message_loop); |
awong
2010/11/16 00:42:12
explicit
| |
19 virtual ~CapturerMac(); | 19 virtual ~CapturerMac(); |
20 | 20 |
21 virtual void ScreenConfigurationChanged(); | 21 virtual void ScreenConfigurationChanged(); |
22 | 22 |
23 private: | 23 private: |
24 virtual void CalculateInvalidRects(); | 24 virtual void CalculateInvalidRects(); |
25 virtual void CaptureRects(const InvalidRects& rects, | 25 virtual void CaptureRects(const InvalidRects& rects, |
26 CaptureCompletedCallback* callback); | 26 CaptureCompletedCallback* callback); |
27 | 27 |
28 void ScreenRefresh(CGRectCount count, const CGRect *rect_array); | 28 void ScreenRefresh(CGRectCount count, const CGRect *rect_array); |
(...skipping 13 matching lines...) Expand all Loading... | |
42 | 42 |
43 void ReleaseBuffers(); | 43 void ReleaseBuffers(); |
44 CGLContextObj cgl_context_; | 44 CGLContextObj cgl_context_; |
45 scoped_array<uint8> buffers_[kNumBuffers]; | 45 scoped_array<uint8> buffers_[kNumBuffers]; |
46 DISALLOW_COPY_AND_ASSIGN(CapturerMac); | 46 DISALLOW_COPY_AND_ASSIGN(CapturerMac); |
47 }; | 47 }; |
48 | 48 |
49 } // namespace remoting | 49 } // namespace remoting |
50 | 50 |
51 #endif // REMOTING_HOST_CAPTURER_MAC_H_ | 51 #endif // REMOTING_HOST_CAPTURER_MAC_H_ |
OLD | NEW |