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 SkPaint_DEFINED | 8 #ifndef SkPaint_DEFINED |
9 #define SkPaint_DEFINED | 9 #define SkPaint_DEFINED |
10 | 10 |
(...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
620 <p /> | 620 <p /> |
621 Pass NULL to clear any previous rasterizer. | 621 Pass NULL to clear any previous rasterizer. |
622 As a convenience, the parameter passed is also returned. | 622 As a convenience, the parameter passed is also returned. |
623 If a previous rasterizer exists in the paint, its reference count is | 623 If a previous rasterizer exists in the paint, its reference count is |
624 decremented. If rasterizer is not NULL, its reference count is | 624 decremented. If rasterizer is not NULL, its reference count is |
625 incremented. | 625 incremented. |
626 @param rasterizer May be NULL. The new rasterizer to be installed in | 626 @param rasterizer May be NULL. The new rasterizer to be installed in |
627 the paint. | 627 the paint. |
628 @return rasterizer | 628 @return rasterizer |
629 */ | 629 */ |
| 630 #ifdef SK_SUPPORT_LEGACY_MINOR_EFFECT_PTR |
630 SkRasterizer* setRasterizer(SkRasterizer* rasterizer); | 631 SkRasterizer* setRasterizer(SkRasterizer* rasterizer); |
| 632 #endif |
631 void setRasterizer(sk_sp<SkRasterizer>); | 633 void setRasterizer(sk_sp<SkRasterizer>); |
632 | 634 |
633 SkImageFilter* getImageFilter() const { return fImageFilter.get(); } | 635 SkImageFilter* getImageFilter() const { return fImageFilter.get(); } |
634 SkImageFilter* setImageFilter(SkImageFilter*); | 636 SkImageFilter* setImageFilter(SkImageFilter*); |
635 void setImageFilter(sk_sp<SkImageFilter>); | 637 void setImageFilter(sk_sp<SkImageFilter>); |
636 | 638 |
637 /** | 639 /** |
638 * Return the paint's SkDrawLooper (if any). Does not affect the looper's | 640 * Return the paint's SkDrawLooper (if any). Does not affect the looper's |
639 * reference count. | 641 * reference count. |
640 */ | 642 */ |
641 SkDrawLooper* getLooper() const { return fLooper.get(); } | 643 SkDrawLooper* getLooper() const { return fLooper.get(); } |
642 | 644 |
643 /** | 645 /** |
644 * Set or clear the looper object. | 646 * Set or clear the looper object. |
645 * <p /> | 647 * <p /> |
646 * Pass NULL to clear any previous looper. | 648 * Pass NULL to clear any previous looper. |
647 * As a convenience, the parameter passed is also returned. | 649 * As a convenience, the parameter passed is also returned. |
648 * If a previous looper exists in the paint, its reference count is | 650 * If a previous looper exists in the paint, its reference count is |
649 * decremented. If looper is not NULL, its reference count is | 651 * decremented. If looper is not NULL, its reference count is |
650 * incremented. | 652 * incremented. |
651 * @param looper May be NULL. The new looper to be installed in the paint. | 653 * @param looper May be NULL. The new looper to be installed in the paint. |
652 * @return looper | 654 * @return looper |
653 */ | 655 */ |
| 656 #ifdef SK_SUPPORT_LEGACY_MINOR_EFFECT_PTR |
654 SkDrawLooper* setLooper(SkDrawLooper* looper); | 657 SkDrawLooper* setLooper(SkDrawLooper* looper); |
| 658 #endif |
655 void setLooper(sk_sp<SkDrawLooper>); | 659 void setLooper(sk_sp<SkDrawLooper>); |
656 | 660 |
657 enum Align { | 661 enum Align { |
658 kLeft_Align, | 662 kLeft_Align, |
659 kCenter_Align, | 663 kCenter_Align, |
660 kRight_Align, | 664 kRight_Align, |
661 }; | 665 }; |
662 enum { | 666 enum { |
663 kAlignCount = 3 | 667 kAlignCount = 3 |
664 }; | 668 }; |
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1148 friend class GrStencilAndCoverTextContext; | 1152 friend class GrStencilAndCoverTextContext; |
1149 friend class GrPathRendering; | 1153 friend class GrPathRendering; |
1150 friend class GrTextUtils; | 1154 friend class GrTextUtils; |
1151 friend class GrGLPathRendering; | 1155 friend class GrGLPathRendering; |
1152 friend class SkScalerContext; | 1156 friend class SkScalerContext; |
1153 friend class SkTextBaseIter; | 1157 friend class SkTextBaseIter; |
1154 friend class SkCanonicalizePaint; | 1158 friend class SkCanonicalizePaint; |
1155 }; | 1159 }; |
1156 | 1160 |
1157 #endif | 1161 #endif |
OLD | NEW |