32 return "Invalid kind";
43 fName.
printf(
"hardstop_special_%03dx%03d_%s", fW, fH,
kindstr(fKind));
102 for (
int i = 0;
i < loops;
i++) {
static const int points[]
const char * kindstr(Kind k)
DEF_BENCH(return new HardStopGradientBench_SpecialHardStops(100, 100, Kind::k001);)
constexpr SkColor SK_ColorYELLOW
constexpr SkColor SK_ColorBLUE
constexpr SkColor SK_ColorRED
constexpr SkColor SK_ColorGREEN
SkISize onGetSize() override
void onDraw(int loops, SkCanvas *canvas) override
HardStopGradientBench_SpecialHardStops(int w, int h, Kind kind)
const char * onGetName() override
void onPreDraw(SkCanvas *canvas) override
void drawPaint(const SkPaint &paint)
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 setShader(sk_sp< SkShader > shader)
void printf(const char format[],...) SK_PRINTF_LIKE(2
const char * c_str() const
PODArray< SkColor > colors
static constexpr SkISize Make(int32_t w, int32_t h)
static constexpr SkPoint Make(float x, float y)