| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2010 The Android Open Source Project | 2 * Copyright 2010 The Android Open Source Project |
| 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 SkDevice_DEFINED | 8 #ifndef SkDevice_DEFINED |
| 9 #define SkDevice_DEFINED | 9 #define SkDevice_DEFINED |
| 10 | 10 |
| 11 #include "SkRefCnt.h" | 11 #include "SkRefCnt.h" |
| 12 #include "SkCanvas.h" | 12 #include "SkCanvas.h" |
| 13 #include "SkColor.h" | 13 #include "SkColor.h" |
| 14 #include "SkImageFilter.h" | |
| 15 #include "SkSurfaceProps.h" | 14 #include "SkSurfaceProps.h" |
| 16 | 15 |
| 17 class SkBitmap; | 16 class SkBitmap; |
| 18 class SkClipStack; | 17 class SkClipStack; |
| 19 class SkDraw; | 18 class SkDraw; |
| 20 class SkDrawFilter; | 19 class SkDrawFilter; |
| 20 class SkImageFilterCache; |
| 21 struct SkIRect; | 21 struct SkIRect; |
| 22 class SkMatrix; | 22 class SkMatrix; |
| 23 class SkMetaData; | 23 class SkMetaData; |
| 24 class SkRegion; | 24 class SkRegion; |
| 25 class GrRenderTarget; | 25 class GrRenderTarget; |
| 26 | 26 |
| 27 class SK_API SkBaseDevice : public SkRefCnt { | 27 class SK_API SkBaseDevice : public SkRefCnt { |
| 28 public: | 28 public: |
| 29 /** | 29 /** |
| 30 * Construct a new device. | 30 * Construct a new device. |
| (...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 387 | 387 |
| 388 virtual bool forceConservativeRasterClip() const { return false; } | 388 virtual bool forceConservativeRasterClip() const { return false; } |
| 389 | 389 |
| 390 // just called by SkCanvas when built as a layer | 390 // just called by SkCanvas when built as a layer |
| 391 void setOrigin(int x, int y) { fOrigin.set(x, y); } | 391 void setOrigin(int x, int y) { fOrigin.set(x, y); } |
| 392 | 392 |
| 393 /** Causes any deferred drawing to the device to be completed. | 393 /** Causes any deferred drawing to the device to be completed. |
| 394 */ | 394 */ |
| 395 virtual void flush() {} | 395 virtual void flush() {} |
| 396 | 396 |
| 397 virtual SkImageFilter::Cache* getImageFilterCache() { return NULL; } | 397 virtual SkImageFilterCache* getImageFilterCache() { return NULL; } |
| 398 | 398 |
| 399 SkIPoint fOrigin; | 399 SkIPoint fOrigin; |
| 400 SkMetaData* fMetaData; | 400 SkMetaData* fMetaData; |
| 401 SkSurfaceProps fSurfaceProps; | 401 SkSurfaceProps fSurfaceProps; |
| 402 | 402 |
| 403 #ifdef SK_DEBUG | 403 #ifdef SK_DEBUG |
| 404 bool fAttachedToCanvas; | 404 bool fAttachedToCanvas; |
| 405 #endif | 405 #endif |
| 406 | 406 |
| 407 typedef SkRefCnt INHERITED; | 407 typedef SkRefCnt INHERITED; |
| 408 }; | 408 }; |
| 409 | 409 |
| 410 #endif | 410 #endif |
| OLD | NEW |