| 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 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1134 * Send an "annotation" to the canvas. The annotation is a key/value pair,
where the key is | 1134 * Send an "annotation" to the canvas. The annotation is a key/value pair,
where the key is |
| 1135 * a null-terminated utf8 string, and the value is a blob of data stored in
an SkData | 1135 * a null-terminated utf8 string, and the value is a blob of data stored in
an SkData |
| 1136 * (which may be null). The annotation is associated with the specified rec
tangle. | 1136 * (which may be null). The annotation is associated with the specified rec
tangle. |
| 1137 * | 1137 * |
| 1138 * The caller still retains its ownership of the data (if any). | 1138 * The caller still retains its ownership of the data (if any). |
| 1139 * | 1139 * |
| 1140 * Note: on may canvas types, this information is ignored, but some canvase
s (e.g. recording | 1140 * Note: on may canvas types, this information is ignored, but some canvase
s (e.g. recording |
| 1141 * a picture or drawing to a PDF document) will pass on this information. | 1141 * a picture or drawing to a PDF document) will pass on this information. |
| 1142 */ | 1142 */ |
| 1143 void drawAnnotation(const SkRect&, const char key[], SkData* value); | 1143 void drawAnnotation(const SkRect&, const char key[], SkData* value); |
| 1144 void drawAnnotation(const SkRect& rect, const char key[], const sk_sp<SkData
>& value) { |
| 1145 this->drawAnnotation(rect, key, value.get()); |
| 1146 } |
| 1144 | 1147 |
| 1145 ////////////////////////////////////////////////////////////////////////// | 1148 ////////////////////////////////////////////////////////////////////////// |
| 1146 #ifdef SK_INTERNAL | 1149 #ifdef SK_INTERNAL |
| 1147 #ifndef SK_SUPPORT_LEGACY_DRAWFILTER | 1150 #ifndef SK_SUPPORT_LEGACY_DRAWFILTER |
| 1148 #define SK_SUPPORT_LEGACY_DRAWFILTER | 1151 #define SK_SUPPORT_LEGACY_DRAWFILTER |
| 1149 #endif | 1152 #endif |
| 1150 #endif | 1153 #endif |
| 1151 | 1154 |
| 1152 #ifdef SK_SUPPORT_LEGACY_DRAWFILTER | 1155 #ifdef SK_SUPPORT_LEGACY_DRAWFILTER |
| 1153 /** Get the current filter object. The filter's reference count is not | 1156 /** Get the current filter object. The filter's reference count is not |
| (...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1566 | 1569 |
| 1567 class SkCanvasClipVisitor { | 1570 class SkCanvasClipVisitor { |
| 1568 public: | 1571 public: |
| 1569 virtual ~SkCanvasClipVisitor(); | 1572 virtual ~SkCanvasClipVisitor(); |
| 1570 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; | 1573 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; |
| 1571 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; | 1574 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; |
| 1572 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; | 1575 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; |
| 1573 }; | 1576 }; |
| 1574 | 1577 |
| 1575 #endif | 1578 #endif |
| OLD | NEW |