Definition at line 125 of file strokedlines.cpp.
◆ StrokedLinesGM()
skiagm::StrokedLinesGM::StrokedLinesGM |
( |
bool |
useDrawPath | ) |
|
|
inline |
◆ getISize()
SkISize skiagm::StrokedLinesGM::getISize |
( |
| ) |
|
|
inlineoverrideprotectedvirtual |
◆ getName()
SkString skiagm::StrokedLinesGM::getName |
( |
| ) |
const |
|
inlineoverrideprotectedvirtual |
Implements skiagm::GM.
Definition at line 132 of file strokedlines.cpp.
132 {
133
135 if (!fUseDrawPath) {
137 }
139 }
void append(const char text[])
◆ onDraw()
void skiagm::StrokedLinesGM::onDraw |
( |
SkCanvas * |
canvas | ) |
|
|
inlineoverrideprotectedvirtual |
Reimplemented from skiagm::GM.
Definition at line 225 of file strokedlines.cpp.
225 {
227
228 for (
int i = 0; i < fPaints.
size(); ++i) {
229 int saveCount = canvas->
save();
232
234 }
235
236 for (
int i = 0; i < fMatrices.
size(); ++i) {
237 int saveCount = canvas->
save();
238 draw_row(canvas, fPaints[0], fMatrices[i], fUseDrawPath);
240
242 }
243 }
static SkScalar draw_row(SkCanvas *canvas, sk_sp< SkImage > img)
void translate(SkScalar dx, SkScalar dy)
void restoreToCount(int saveCount)
static const SkMatrix & I()
◆ onOnceBeforeDraw()
void skiagm::StrokedLinesGM::onOnceBeforeDraw |
( |
| ) |
|
|
inlineoverrideprotectedvirtual |
Reimplemented from skiagm::GM.
Definition at line 145 of file strokedlines.cpp.
145 {
146
147 {
148
152 }
153 {
154
157
160
162 }
163 {
164
166 int intervalCount = (
int) std::size(intervals);
170
172 }
173 {
174
179
182 m.preScale(3.0f, 3.0f);
183
188 }
189 {
190
195 }
196
197
198 {
199
202
204 }
205 {
206
208 m.setSkew(0.3f, 0.5f);
209
211 }
212 {
213
218
220 }
221
223 }
@ kOuter_SkBlurStyle
nothing inside, fuzzy outside
constexpr SkColor SK_ColorRED
constexpr SkColor SK_ColorGREEN
constexpr SkColor SK_ColorWHITE
Type::kYUV Type::kRGBA() int(0.7 *637)
sk_sp< SkShader > makeShader(SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &, const SkMatrix *localMatrix=nullptr) const
void allocN32Pixels(int width, int height, bool isOpaque=false)
uint32_t * getAddr32(int x, int y) const
static sk_sp< SkPathEffect > Make(const SkScalar intervals[], int count, SkScalar phase)
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)
static sk_sp< SkMaskFilter > MakeBlur(SkBlurStyle style, SkScalar sigma, bool respectCTM=true)
PODArray< SkColor > colors
static constexpr float kStrokeWidth
The documentation for this class was generated from the following file: