Flutter Engine
flutter::Shader Class Reference

#include <shader.h>

Inheritance diagram for flutter::Shader:
flutter::RefCountedDartWrappable< Shader > fml::RefCountedThreadSafe< Shader > tonic::DartWrappable fml::internal::RefCountedThreadSafeBase flutter::CanvasGradient flutter::ImageShader

Public Member Functions

 ~Shader () override
 
sk_sp< SkShader > shader ()
 
void set_shader (flutter::SkiaGPUObject< SkShader > shader)
 
- Public Member Functions inherited from flutter::RefCountedDartWrappable< Shader >
virtual void RetainDartWrappableReference () const override
 
virtual void ReleaseDartWrappableReference () const override
 
- Public Member Functions inherited from fml::RefCountedThreadSafe< Shader >
void Release () const
 
- Public Member Functions inherited from fml::internal::RefCountedThreadSafeBase
void AddRef () const
 
bool HasOneRef () const
 
void AssertHasOneRef () const
 
- Public Member Functions inherited from tonic::DartWrappable
 DartWrappable ()
 
virtual const DartWrapperInfoGetDartWrapperInfo () const =0
 
virtual size_t GetAllocationSize () const
 
Dart_Handle CreateDartWrapper (DartState *dart_state)
 
void AssociateWithDartWrapper (Dart_Handle wrappable)
 
void ClearDartWrapper ()
 
Dart_WeakPersistentHandle dart_wrapper () const
 

Protected Member Functions

 Shader (flutter::SkiaGPUObject< SkShader > shader={})
 
- Protected Member Functions inherited from fml::RefCountedThreadSafe< Shader >
 RefCountedThreadSafe ()
 
 ~RefCountedThreadSafe ()
 
- Protected Member Functions inherited from fml::internal::RefCountedThreadSafeBase
 RefCountedThreadSafeBase ()
 
 ~RefCountedThreadSafeBase ()
 
bool Release () const
 
void Adopt ()
 
- Protected Member Functions inherited from tonic::DartWrappable
virtual ~DartWrappable ()
 

Additional Inherited Members

- Public Types inherited from tonic::DartWrappable
enum  DartNativeFields {
  kPeerIndex,
  kWrapperInfoIndex,
  kNumberOfNativeFields
}
 
- Static Protected Member Functions inherited from tonic::DartWrappable
static Dart_PersistentHandle GetTypeForWrapper (tonic::DartState *dart_state, const tonic::DartWrapperInfo &wrapper_info)
 

Detailed Description

Definition at line 15 of file shader.h.

Constructor & Destructor Documentation

◆ ~Shader()

flutter::Shader::~Shader ( )
overridedefault

Referenced by Shader().

◆ Shader()

flutter::Shader::Shader ( flutter::SkiaGPUObject< SkShader >  shader = {})
protected

Definition at line 13 of file shader.cc.

References ~Shader().

Referenced by set_shader().

14  : shader_(std::move(shader)) {}

Member Function Documentation

◆ set_shader()

void flutter::Shader::set_shader ( flutter::SkiaGPUObject< SkShader >  shader)
inline

◆ shader()

sk_sp<SkShader> flutter::Shader::shader ( )
inline

Definition at line 22 of file shader.h.

References flutter::SkiaGPUObject< T >::get().

Referenced by flutter::Paint::Paint(), flutter::SceneBuilder::pushShaderMask(), and set_shader().

22 { return shader_.get(); }
sk_sp< SkiaObjectType > get() const

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