Definition at line 133 of file analytic_gradients.cpp.
◆ AnalyticGradientShaderGM()
AnalyticGradientShaderGM::AnalyticGradientShaderGM |
( |
| ) |
|
|
inline |
◆ getISize()
SkISize AnalyticGradientShaderGM::getISize |
( |
| ) |
|
|
inlineoverrideprotectedvirtual |
◆ getName()
SkString AnalyticGradientShaderGM::getName |
( |
| ) |
const |
|
inlineoverrideprotectedvirtual |
◆ onDraw()
void AnalyticGradientShaderGM::onDraw |
( |
SkCanvas * |
canvas | ) |
|
|
inlineoverrideprotectedvirtual |
Reimplemented from skiagm::GM.
Definition at line 144 of file analytic_gradients.cpp.
144 {
146
147 for (
int cellRow = 0; cellRow <
NUM_ROWS; cellRow++) {
148
150
151 for (
int cellCol = 0; cellCol <
NUM_COLS; cellCol++) {
152
153
154
155 int colorCount = colorCounts[cellCol];
156
158
159
160
163 int j = 0;
164 for (
int i = 0;
i < colorCount;
i++) {
167 j++;
168 }
169
173 positions.get(),
174 colorCount,
176 0,
177 nullptr);
178
180 }
181 }
182 }
static const int points[]
static void shade_rect(SkCanvas *canvas, sk_sp< SkShader > shader, int cellRow, int cellCol)
const int * M_POSITIONS[]
const int * INTERVAL_COLOR_COUNTS[]
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)
PODArray< SkColor > colors
static constexpr SkPoint Make(float x, float y)
The documentation for this class was generated from the following file: