Home | History | Annotate | Download | only in ext

Lines Matching full:skia

8 #include "third_party/skia/include/core/SkRefCnt.h"
10 namespace skia {
12 // When creating/receiving a ref-counted pointer from Skia, wrap that pointer in
17 // skia::RefPtr<SkShader> shader = skia::AdoptRef(SkGradientShader::Create());
20 // When passing around a ref-counted pointer to methods outside of Skia, always
21 // pass around the skia::RefPtr instead of the raw pointer. An example method
23 // void AMethodThatSavesAShader(const skia::RefPtr<SkShader>& shader) {
26 // skia::RefPtr<SkShader> member_refptr_;
28 // When returning a ref-counted pointer, also return the skia::RefPtr instead.
30 // skia::RefPtr<SkShader> MakeAShader() {
31 // return skia::AdoptRef(SkGradientShader::Create());
36 // skia::SharePtr helper:
38 // skia::RefPtr<SkShader> shader = skia::SharePtr(paint.getShader());
41 // AdoptRef() the raw pointer immediately into a skia::RefPtr and always work
42 // with skia::RefPtr instances instead, the ref-counting will be taken care of
93 // This function cannot be public because Skia starts its ref-counted
116 } // namespace skia