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 SkCanvasStack_DEFINED | 8 #ifndef SkCanvasStack_DEFINED |
9 #define SkCanvasStack_DEFINED | 9 #define SkCanvasStack_DEFINED |
10 | 10 |
(...skipping 13 matching lines...) Expand all Loading... |
24 * that do not make sense in the context of our CanvasStack, but since we | 24 * that do not make sense in the context of our CanvasStack, but since we |
25 * can share most of the other implementation of NWay we override those | 25 * can share most of the other implementation of NWay we override those |
26 * methods to be no-ops. | 26 * methods to be no-ops. |
27 */ | 27 */ |
28 void addCanvas(SkCanvas*) override { SkDEBUGFAIL("Invalid Op"); } | 28 void addCanvas(SkCanvas*) override { SkDEBUGFAIL("Invalid Op"); } |
29 void removeCanvas(SkCanvas*) override { SkDEBUGFAIL("Invalid Op"); } | 29 void removeCanvas(SkCanvas*) override { SkDEBUGFAIL("Invalid Op"); } |
30 | 30 |
31 protected: | 31 protected: |
32 void didSetMatrix(const SkMatrix&) override; | 32 void didSetMatrix(const SkMatrix&) override; |
33 | 33 |
34 void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) override; | 34 void onClipRect(const SkRect&, ClipOp, ClipEdgeStyle) override; |
35 void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) override; | 35 void onClipRRect(const SkRRect&, ClipOp, ClipEdgeStyle) override; |
36 void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) override; | 36 void onClipPath(const SkPath&, ClipOp, ClipEdgeStyle) override; |
37 void onClipRegion(const SkRegion&, SkRegion::Op) override; | 37 void onClipRegion(const SkRegion&, ClipOp) override; |
38 | 38 |
39 private: | 39 private: |
40 void clipToZOrderedBounds(); | 40 void clipToZOrderedBounds(); |
41 | 41 |
42 struct CanvasData { | 42 struct CanvasData { |
43 SkIPoint origin; | 43 SkIPoint origin; |
44 SkRegion requiredClip; | 44 SkRegion requiredClip; |
45 }; | 45 }; |
46 | 46 |
47 SkTArray<CanvasData> fCanvasData; | 47 SkTArray<CanvasData> fCanvasData; |
48 | 48 |
49 typedef SkNWayCanvas INHERITED; | 49 typedef SkNWayCanvas INHERITED; |
50 }; | 50 }; |
51 | 51 |
52 #endif | 52 #endif |
OLD | NEW |