53 {
54 constexpr SkScalar kMaxR = kMaxRadius + kMaxBlurRadius;
55
56 auto almostCircleMaker = [] (
SkScalar radius) {
61 };
62
66 };
67
70
74 SkPath almostCircle = almostCircleMaker(fAnimRadius);
81 } else {
86 constexpr SkScalar kBlurRadiusSteps = 5;
88 kPad + kMinRadius + kMaxBlurRadius);
89 constexpr SkScalar kDeltaRadius = (kMaxRadius - kMinRadius) / kRadiusSteps;
90 constexpr SkScalar kDeltaBlurRadius = (kMaxBlurRadius - kMinBlurRadius) /
91 kBlurRadiusSteps;
93 if (!benchMode) {
94 for (int r = 0; r < kRadiusSteps - 1; ++r) {
95 const SkScalar radius = r * kDeltaRadius + kMinRadius;
96 lineWidth += 2 * (radius + kMaxBlurRadius) +
kPad;
97 }
98 }
99 for (int br = 0; br < kBlurRadiusSteps; ++br) {
100 SkScalar blurRadius = br * kDeltaBlurRadius + kMinBlurRadius;
101 if (benchMode) {
102 blurRadius += fRandom.
nextSScalar1() * kDeltaBlurRadius;
103 }
104 const SkScalar maxRowR = blurRadius + kMaxRadius;
105 paint.setMaskFilter(blurMaker(blurRadius));
107 for (int r = 0; r < kRadiusSteps; ++r) {
108 SkScalar radius = r * kDeltaRadius + kMinRadius;
109 if (benchMode) {
111 }
113 if (!benchMode) {
114 almostCircle = almostCircleMaker(radius);
115 }
119 if (!benchMode) {
121 }
123 const SkScalar maxColR = radius + kMaxBlurRadius;
125 }
127 if (!benchMode) {
131 if (br != kBlurRadiusSteps - 1) {
132 canvas->
drawLine(0, lineY, lineWidth, lineY, blackPaint);
133 }
134 }
136 }
138 }
139 }
@ kNormal_SkBlurStyle
fuzzy inside and outside
constexpr SkColor SK_ColorBLACK
static SkScalar SK_SPI ConvertRadiusToSigma(SkScalar radius)
void translate(SkScalar dx, SkScalar dy)
void drawLine(SkScalar x0, SkScalar y0, SkScalar x1, SkScalar y1, const SkPaint &paint)
virtual SkISize getBaseLayerSize() const
void drawPath(const SkPath &path, const SkPaint &paint)
void drawCircle(SkScalar cx, SkScalar cy, SkScalar radius, const SkPaint &paint)
static sk_sp< SkMaskFilter > MakeBlur(SkBlurStyle style, SkScalar sigma, bool respectCTM=true)
void setColor(SkColor color)
void setMaskFilter(sk_sp< SkMaskFilter > maskFilter)
SkPathBuilder & addArc(const SkRect &oval, SkScalar startAngleDeg, SkScalar sweepAngleDeg)
SkPathBuilder & setIsVolatile(bool isVolatile)
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 SkRect MakeXYWH(float x, float y, float w, float h)