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

Side by Side Diff: remoting/host/capturer_mac.h

Issue 3013015: Initial pass at integrating Differ into the chromoting host code.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « remoting/host/capturer_linux.cc ('k') | remoting/host/capturer_mac.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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();
19 virtual ~CapturerMac(); 19 virtual ~CapturerMac();
20 20
21 virtual void CaptureRects(const RectVector& rects,
22 CaptureCompletedCallback* callback);
23
24 virtual void ScreenConfigurationChanged(); 21 virtual void ScreenConfigurationChanged();
25 22
26 private: 23 private:
24 virtual void CalculateInvalidRects();
25 virtual void CaptureRects(const InvalidRects& rects,
26 CaptureCompletedCallback* callback);
27
27 void ScreenRefresh(CGRectCount count, const CGRect *rect_array); 28 void ScreenRefresh(CGRectCount count, const CGRect *rect_array);
28 void ScreenUpdateMove(CGScreenUpdateMoveDelta delta, 29 void ScreenUpdateMove(CGScreenUpdateMoveDelta delta,
29 size_t count, 30 size_t count,
30 const CGRect *rect_array); 31 const CGRect *rect_array);
31 static void ScreenRefreshCallback(CGRectCount count, 32 static void ScreenRefreshCallback(CGRectCount count,
32 const CGRect *rect_array, 33 const CGRect *rect_array,
33 void *user_parameter); 34 void *user_parameter);
34 static void ScreenUpdateMoveCallback(CGScreenUpdateMoveDelta delta, 35 static void ScreenUpdateMoveCallback(CGScreenUpdateMoveDelta delta,
35 size_t count, 36 size_t count,
36 const CGRect *rect_array, 37 const CGRect *rect_array,
37 void *user_parameter); 38 void *user_parameter);
38 static void DisplaysReconfiguredCallback(CGDirectDisplayID display, 39 static void DisplaysReconfiguredCallback(CGDirectDisplayID display,
39 CGDisplayChangeSummaryFlags flags, 40 CGDisplayChangeSummaryFlags flags,
40 void *user_parameter); 41 void *user_parameter);
41 42
42 void ReleaseBuffers(); 43 void ReleaseBuffers();
43 CGLContextObj cgl_context_; 44 CGLContextObj cgl_context_;
44 scoped_array<uint8> buffers_[kNumBuffers]; 45 scoped_array<uint8> buffers_[kNumBuffers];
45 DISALLOW_COPY_AND_ASSIGN(CapturerMac); 46 DISALLOW_COPY_AND_ASSIGN(CapturerMac);
46 }; 47 };
47 48
48 } // namespace remoting 49 } // namespace remoting
49 50
50 #endif // REMOTING_HOST_CAPTURER_MAC_H_ 51 #endif // REMOTING_HOST_CAPTURER_MAC_H_
OLDNEW
« no previous file with comments | « remoting/host/capturer_linux.cc ('k') | remoting/host/capturer_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698