38class VenetianBlindsAdapter final :
public MaskShaderEffectBase {
43 const AnimationBuilder* abuilder) {
45 new VenetianBlindsAdapter(jprops, std::move(layer), layer_size, abuilder));
51 const AnimationBuilder* abuilder)
54 kCompletion_Index = 0,
60 EffectBinder(jprops, *abuilder,
this)
61 .bind(kCompletion_Index, fCompletion)
62 .bind( kDirection_Index, fDirection )
63 .bind( kWidth_Index, fWidth )
64 .bind( kFeather_Index, fFeather );
67 MaskInfo onMakeMask()
const override {
68 if (fCompletion >= 100) {
74 if (fCompletion <= 0) {
76 return {
nullptr,
true };
79 static constexpr float kFeatherSigmaFactor = 3.0f,
82 const auto t = fCompletion * 0.01f,
85 feather =
std::max(fFeather * kFeatherSigmaFactor, kMinFeather),
133 SkASSERT(0 <= g01 && g01 <= g23 && g23 <= 1);
137 colors[] = { c01, c23, c23, c01 };
149 0.5f * this->layerSize().
height()),
151 -
size * std::sin(angle));
154 center + grad_vec * (df0 + 0),
155 center + grad_vec * (df0 + 1),
constexpr SkColor SK_ColorTRANSPARENT
static constexpr SkColor SkColorSetA(SkColor c, U8CPU a)
constexpr SkColor SK_ColorWHITE
static constexpr float sk_ieee_float_divide(float numer, float denom)
#define INHERITED(method,...)
#define SkDegreesToRadians(degrees)
#define SkScalarRoundToInt(x)
static sk_sp< SkShader > MakeLinear(const SkPoint pts[2], const SkColor colors[], const SkScalar pos[], int count, SkTileMode mode, uint32_t flags=0, const SkMatrix *localMatrix=nullptr)
void attachDiscardableAdapter(sk_sp< T > adapter) const
static float max(float r, float g, float b)
static float min(float r, float g, float b)
SK_API sk_sp< SkDocument > Make(SkWStream *dst, const SkSerialProcs *=nullptr, std::function< void(const SkPicture *)> onEndPage=nullptr)
PODArray< SkColor > colors
SK_API sk_sp< SkShader > Color(SkColor)
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
static constexpr SkPoint Make(float x, float y)