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 SkNulCanvas_DEFINED | 8 #ifndef SkNulCanvas_DEFINED |
9 #define SkNulCanvas_DEFINED | 9 #define SkNulCanvas_DEFINED |
10 | 10 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 bool doAntiAlias = false) {return true;} | 48 bool doAntiAlias = false) {return true;} |
49 virtual bool clipPath(const SkPath& path, | 49 virtual bool clipPath(const SkPath& path, |
50 SkRegion::Op op = SkRegion::kIntersect_Op, | 50 SkRegion::Op op = SkRegion::kIntersect_Op, |
51 bool doAntiAlias = false) {return true;} | 51 bool doAntiAlias = false) {return true;} |
52 virtual bool clipRegion(const SkRegion& deviceRgn, | 52 virtual bool clipRegion(const SkRegion& deviceRgn, |
53 SkRegion::Op op = SkRegion::kIntersect_Op) {return t
rue;} | 53 SkRegion::Op op = SkRegion::kIntersect_Op) {return t
rue;} |
54 virtual void clear(SkColor) {} | 54 virtual void clear(SkColor) {} |
55 virtual void drawPaint(const SkPaint& paint) {} | 55 virtual void drawPaint(const SkPaint& paint) {} |
56 virtual void drawPoints(PointMode mode, size_t count, const SkPoint pts[], | 56 virtual void drawPoints(PointMode mode, size_t count, const SkPoint pts[], |
57 const SkPaint& paint) {} | 57 const SkPaint& paint) {} |
| 58 virtual void drawRect(const SkRect& rect, const SkPaint& paint) {} |
58 virtual void drawOval(const SkRect& oval, const SkPaint&) {} | 59 virtual void drawOval(const SkRect& oval, const SkPaint&) {} |
59 virtual void drawRRect(const SkRRect& rrect, const SkPaint& paint) {} | 60 virtual void drawRRect(const SkRRect& rrect, const SkPaint& paint) {} |
| 61 virtual void drawPath(const SkPath& path, const SkPaint& paint) {} |
60 virtual void drawBitmap(const SkBitmap& bitmap, SkScalar left, SkScalar top, | 62 virtual void drawBitmap(const SkBitmap& bitmap, SkScalar left, SkScalar top, |
61 const SkPaint* paint = NULL) {} | 63 const SkPaint* paint = NULL) {} |
62 virtual void drawBitmapRectToRect(const SkBitmap& bitmap, const SkRect* src, | 64 virtual void drawBitmapRectToRect(const SkBitmap& bitmap, const SkRect* src, |
63 const SkRect& dst, | 65 const SkRect& dst, |
64 const SkPaint* paint, | 66 const SkPaint* paint, |
65 DrawBitmapRectFlags flags) {} | 67 DrawBitmapRectFlags flags) {} |
66 virtual void drawBitmapMatrix(const SkBitmap& bitmap, const SkMatrix& m, | 68 virtual void drawBitmapMatrix(const SkBitmap& bitmap, const SkMatrix& m, |
67 const SkPaint* paint = NULL) {} | 69 const SkPaint* paint = NULL) {} |
68 virtual void drawBitmapNine(const SkBitmap& bitmap, const SkIRect& center, | 70 virtual void drawBitmapNine(const SkBitmap& bitmap, const SkIRect& center, |
69 const SkRect& dst, const SkPaint* paint = NULL)
{} | 71 const SkRect& dst, const SkPaint* paint = NULL)
{} |
(...skipping 16 matching lines...) Expand all Loading... |
86 const uint16_t indices[], int indexCount, | 88 const uint16_t indices[], int indexCount, |
87 const SkPaint& paint) {} | 89 const SkPaint& paint) {} |
88 virtual void drawData(const void* data, size_t length) {} | 90 virtual void drawData(const void* data, size_t length) {} |
89 virtual void beginCommentGroup(const char* description) {} | 91 virtual void beginCommentGroup(const char* description) {} |
90 virtual void addComment(const char* kywd, const char* value) {} | 92 virtual void addComment(const char* kywd, const char* value) {} |
91 virtual void endCommentGroup() {} | 93 virtual void endCommentGroup() {} |
92 virtual SkBounder* setBounder(SkBounder* bounder) {return NULL;} | 94 virtual SkBounder* setBounder(SkBounder* bounder) {return NULL;} |
93 virtual SkDrawFilter* setDrawFilter(SkDrawFilter* filter) {return NULL;} | 95 virtual SkDrawFilter* setDrawFilter(SkDrawFilter* filter) {return NULL;} |
94 | 96 |
95 protected: | 97 protected: |
96 virtual void onDrawRect(const SkRect& rect, const SkPaint& paint) {} | |
97 virtual void onDrawPath(const SkPath& path, const SkPaint& paint) {} | |
98 virtual SkCanvas* canvasForDrawIter() {return NULL;} | 98 virtual SkCanvas* canvasForDrawIter() {return NULL;} |
99 virtual SkBaseDevice* setDevice(SkBaseDevice* device) {return NULL;} | 99 virtual SkBaseDevice* setDevice(SkBaseDevice* device) {return NULL;} |
100 | 100 |
101 private: | 101 private: |
102 typedef SkCanvas INHERITED; | 102 typedef SkCanvas INHERITED; |
103 }; | 103 }; |
104 | 104 |
105 #endif // SkNulCanvas_DEFINED | 105 #endif // SkNulCanvas_DEFINED |
OLD | NEW |