OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef SkTrackDevice_DEFINED | 8 #ifndef SkTrackDevice_DEFINED |
9 #define SkTrackDevice_DEFINED | 9 #define SkTrackDevice_DEFINED |
10 | 10 |
(...skipping 11 matching lines...) Expand all Loading... |
22 * after(); // - checks if pixels of interest, and issue a breakpoint. | 22 * after(); // - checks if pixels of interest, and issue a breakpoint. |
23 * | 23 * |
24 */ | 24 */ |
25 class SkTrackDevice : public SkBitmapDevice { | 25 class SkTrackDevice : public SkBitmapDevice { |
26 public: | 26 public: |
27 SK_DECLARE_INST_COUNT(SkTrackDevice) | 27 SK_DECLARE_INST_COUNT(SkTrackDevice) |
28 | 28 |
29 SkTrackDevice(const SkBitmap& bitmap) : SkBitmapDevice(bitmap) | 29 SkTrackDevice(const SkBitmap& bitmap) : SkBitmapDevice(bitmap) |
30 , fTracker(NULL) {} | 30 , fTracker(NULL) {} |
31 | 31 |
32 SkTrackDevice(const SkBitmap& bitmap, const SkDeviceProperties& deviceProper
ties) | |
33 : SkBitmapDevice(bitmap, deviceProperties) | |
34 , fTracker(NULL) {} | |
35 | |
36 virtual ~SkTrackDevice() {} | 32 virtual ~SkTrackDevice() {} |
37 | 33 |
38 // Install a tracker - we can reuse the tracker between multiple devices, an
d the state of the | 34 // Install a tracker - we can reuse the tracker between multiple devices, an
d the state of the |
39 // tracker is preserved - number and location of poinbts, ... | 35 // tracker is preserved - number and location of poinbts, ... |
40 void installTracker(SkTracker* tracker) { | 36 void installTracker(SkTracker* tracker) { |
41 fTracker = tracker; | 37 fTracker = tracker; |
42 fTracker->newFrame(); | 38 fTracker->newFrame(); |
43 } | 39 } |
44 | 40 |
45 protected: | 41 protected: |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 } | 167 } |
172 } | 168 } |
173 | 169 |
174 private: | 170 private: |
175 SkTracker* fTracker; | 171 SkTracker* fTracker; |
176 | 172 |
177 typedef SkBitmapDevice INHERITED; | 173 typedef SkBitmapDevice INHERITED; |
178 }; | 174 }; |
179 | 175 |
180 #endif // SkTrackDevice_DEFINED | 176 #endif // SkTrackDevice_DEFINED |
OLD | NEW |