OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The Android Open Source Project | 2 * Copyright 2006 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 SkCanvas_DEFINED | 8 #ifndef SkCanvas_DEFINED |
9 #define SkCanvas_DEFINED | 9 #define SkCanvas_DEFINED |
10 | 10 |
(...skipping 1093 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1104 kEmpty_ClipType = 0, | 1104 kEmpty_ClipType = 0, |
1105 kRect_ClipType, | 1105 kRect_ClipType, |
1106 kComplex_ClipType | 1106 kComplex_ClipType |
1107 }; | 1107 }; |
1108 /** Returns a description of the total clip; may be cheaper than | 1108 /** Returns a description of the total clip; may be cheaper than |
1109 getting the clip and querying it directly. | 1109 getting the clip and querying it directly. |
1110 */ | 1110 */ |
1111 virtual ClipType getClipType() const; | 1111 virtual ClipType getClipType() const; |
1112 #endif | 1112 #endif |
1113 | 1113 |
| 1114 #ifdef SK_SUPPORT_LEGACY_GETTOTALCLIP |
| 1115 /** DEPRECATED -- need to move this guy to private/friend |
| 1116 * Return the current device clip (concatenation of all clip calls). |
| 1117 * This does not account for the translate in any of the devices. |
| 1118 * @return the current device clip (concatenation of all clip calls). |
| 1119 */ |
| 1120 const SkRegion& getTotalClip() const; |
| 1121 #endif |
| 1122 |
1114 /** Return the clip stack. The clip stack stores all the individual | 1123 /** Return the clip stack. The clip stack stores all the individual |
1115 * clips organized by the save/restore frame in which they were | 1124 * clips organized by the save/restore frame in which they were |
1116 * added. | 1125 * added. |
1117 * @return the current clip stack ("list" of individual clip elements) | 1126 * @return the current clip stack ("list" of individual clip elements) |
1118 */ | 1127 */ |
1119 const SkClipStack* getClipStack() const { | 1128 const SkClipStack* getClipStack() const { |
1120 return &fClipStack; | 1129 return &fClipStack; |
1121 } | 1130 } |
1122 | 1131 |
1123 typedef SkCanvasClipVisitor ClipVisitor; | 1132 typedef SkCanvasClipVisitor ClipVisitor; |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1488 | 1497 |
1489 class SkCanvasClipVisitor { | 1498 class SkCanvasClipVisitor { |
1490 public: | 1499 public: |
1491 virtual ~SkCanvasClipVisitor(); | 1500 virtual ~SkCanvasClipVisitor(); |
1492 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; | 1501 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; |
1493 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; | 1502 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; |
1494 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; | 1503 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; |
1495 }; | 1504 }; |
1496 | 1505 |
1497 #endif | 1506 #endif |
OLD | NEW |