Flutter Engine
The Flutter Engine
Static Public Member Functions | Protected Member Functions | Friends | List of all members
sksg::Color Class Reference

#include <SkSGPaint.h>

Inheritance diagram for sksg::Color:
sksg::PaintNode sksg::Node SkRefCnt SkRefCntBase

Static Public Member Functions

static sk_sp< ColorMake (SkColor c)
 

Protected Member Functions

SkRect onRevalidate (InvalidationController *, const SkMatrix &) override
 
void onApplyToPaint (SkPaint *) const override
 
- Protected Member Functions inherited from sksg::PaintNode
 PaintNode ()
 
virtual void onApplyToPaint (SkPaint *) const =0
 
- Protected Member Functions inherited from sksg::Node
 Node (uint32_t invalTraits)
 
 ~Node () override
 
const SkRectbounds () const
 
bool hasInval () const
 
virtual SkRect onRevalidate (InvalidationController *, const SkMatrix &ctm)=0
 
void observeInval (const sk_sp< Node > &)
 
void unobserveInval (const sk_sp< Node > &)
 

Friends

class skottie::internal::AnimationBuilder
 

Additional Inherited Members

- Public Member Functions inherited from sksg::PaintNode
SkPaint makePaint () const
 
- Public Member Functions inherited from sksg::Node
const SkRectrevalidate (InvalidationController *, const SkMatrix &)
 
void invalidate (bool damage=true)
 
- Public Member Functions inherited from SkRefCntBase
 SkRefCntBase ()
 
virtual ~SkRefCntBase ()
 
bool unique () const
 
void ref () const
 
void unref () const
 
- Protected Types inherited from sksg::Node
enum  InvalTraits { kBubbleDamage_Trait = 1 << 0 , kOverrideDamage_Trait = 1 << 1 }
 

Detailed Description

Concrete Paint node, wrapping an SkColor.

Definition at line 69 of file SkSGPaint.h.

Member Function Documentation

◆ Make()

sk_sp< Color > sksg::Color::Make ( SkColor  c)
static

Definition at line 44 of file SkSGPaint.cpp.

44 {
45 return sk_sp<Color>(new Color(c));
46}

◆ onApplyToPaint()

void sksg::Color::onApplyToPaint ( SkPaint paint) const
overrideprotectedvirtual

Implements sksg::PaintNode.

Definition at line 56 of file SkSGPaint.cpp.

56 {
57 paint->setColor(fColor);
58}
const Paint & paint
Definition: color_source.cc:38

◆ onRevalidate()

SkRect sksg::Color::onRevalidate ( InvalidationController ic,
const SkMatrix ctm 
)
overrideprotectedvirtual

Implements sksg::Node.

Definition at line 50 of file SkSGPaint.cpp.

50 {
51 SkASSERT(this->hasInval());
52
53 return SkRect::MakeEmpty();
54}
#define SkASSERT(cond)
Definition: SkAssert.h:116
bool hasInval() const
Definition: SkSGNode.h:60
static constexpr SkRect MakeEmpty()
Definition: SkRect.h:595

Friends And Related Function Documentation

◆ skottie::internal::AnimationBuilder

Definition at line 85 of file SkSGPaint.h.


The documentation for this class was generated from the following files: