| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 #ifndef SkPictureRecord_DEFINED | 8 #ifndef SkPictureRecord_DEFINED |
| 9 #define SkPictureRecord_DEFINED | 9 #define SkPictureRecord_DEFINED |
| 10 | 10 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 // a 3 byte value into/out of a uint32_t | 23 // a 3 byte value into/out of a uint32_t |
| 24 #define MASK_24 0x00FFFFFF | 24 #define MASK_24 0x00FFFFFF |
| 25 #define UNPACK_8_24(combined, small, large) \ | 25 #define UNPACK_8_24(combined, small, large) \ |
| 26 small = (combined >> 24) & 0xFF; \ | 26 small = (combined >> 24) & 0xFF; \ |
| 27 large = combined & MASK_24; | 27 large = combined & MASK_24; |
| 28 #define PACK_8_24(small, large) ((small << 24) | large) | 28 #define PACK_8_24(small, large) ((small << 24) | large) |
| 29 | 29 |
| 30 | 30 |
| 31 class SkPictureRecord : public SkCanvas { | 31 class SkPictureRecord : public SkCanvas { |
| 32 public: | 32 public: |
| 33 SkPictureRecord(uint32_t recordFlags, SkDevice*); | 33 SkPictureRecord(uint32_t recordFlags, SkBaseDevice*); |
| 34 virtual ~SkPictureRecord(); | 34 virtual ~SkPictureRecord(); |
| 35 | 35 |
| 36 virtual SkDevice* setDevice(SkDevice* device) SK_OVERRIDE; | 36 virtual SkBaseDevice* setDevice(SkBaseDevice* device) SK_OVERRIDE; |
| 37 | 37 |
| 38 virtual int save(SaveFlags) SK_OVERRIDE; | 38 virtual int save(SaveFlags) SK_OVERRIDE; |
| 39 virtual int saveLayer(const SkRect* bounds, const SkPaint*, SaveFlags) SK_OV
ERRIDE; | 39 virtual int saveLayer(const SkRect* bounds, const SkPaint*, SaveFlags) SK_OV
ERRIDE; |
| 40 virtual void restore() SK_OVERRIDE; | 40 virtual void restore() SK_OVERRIDE; |
| 41 virtual bool translate(SkScalar dx, SkScalar dy) SK_OVERRIDE; | 41 virtual bool translate(SkScalar dx, SkScalar dy) SK_OVERRIDE; |
| 42 virtual bool scale(SkScalar sx, SkScalar sy) SK_OVERRIDE; | 42 virtual bool scale(SkScalar sx, SkScalar sy) SK_OVERRIDE; |
| 43 virtual bool rotate(SkScalar degrees) SK_OVERRIDE; | 43 virtual bool rotate(SkScalar degrees) SK_OVERRIDE; |
| 44 virtual bool skew(SkScalar sx, SkScalar sy) SK_OVERRIDE; | 44 virtual bool skew(SkScalar sx, SkScalar sy) SK_OVERRIDE; |
| 45 virtual bool concat(const SkMatrix& matrix) SK_OVERRIDE; | 45 virtual bool concat(const SkMatrix& matrix) SK_OVERRIDE; |
| 46 virtual void setMatrix(const SkMatrix& matrix) SK_OVERRIDE; | 46 virtual void setMatrix(const SkMatrix& matrix) SK_OVERRIDE; |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 uint32_t fRecordFlags; | 262 uint32_t fRecordFlags; |
| 263 int fInitialSaveCount; | 263 int fInitialSaveCount; |
| 264 | 264 |
| 265 friend class SkPicturePlayback; | 265 friend class SkPicturePlayback; |
| 266 friend class SkPictureTester; // for unit testing | 266 friend class SkPictureTester; // for unit testing |
| 267 | 267 |
| 268 typedef SkCanvas INHERITED; | 268 typedef SkCanvas INHERITED; |
| 269 }; | 269 }; |
| 270 | 270 |
| 271 #endif | 271 #endif |
| OLD | NEW |