Flutter Engine
The Flutter Engine
SkRecorder.cpp
Go to the documentation of this file.
1/*
2 * Copyright 2014 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
9
11#include "include/core/SkData.h"
21#include "include/core/SkRect.h"
33#include "src/core/SkRecord.h"
34#include "src/core/SkRecords.h"
35#include "src/text/GlyphRun.h"
37
38#include <cstdint>
39#include <cstring>
40#include <memory>
41#include <new>
42
43class SkBlender;
44class SkMesh;
45class SkPath;
46class SkRRect;
47class SkRegion;
48class SkSurfaceProps;
49enum class SkBlendMode;
50enum class SkClipOp;
51struct SkDrawShadowRec;
52
53using namespace skia_private;
54
56 for(SkDrawable* p : fArray) {
57 p->unref();
58 }
59 fArray.reset();
60}
61
63 const int count = fArray.size();
64 if (0 == count) {
65 return nullptr;
66 }
68 for (int i = 0; i < count; ++i) {
69 pics[i] = fArray[i]->makePictureSnapshot().release();
70 }
71 return new SkBigPicture::SnapshotArray(pics.release(), count);
72}
73
75 *fArray.append() = SkRef(drawable);
76}
77
78///////////////////////////////////////////////////////////////////////////////////////////////
79
81 SkIRect picBounds = bounds.roundOut();
82 // roundOut() saturates the float edges to +/-SK_MaxS32FitsInFloat (~2billion), but this is
83 // large enough that width/height calculations will overflow, leading to negative dimensions.
84 static constexpr int32_t kSafeEdge = SK_MaxS32FitsInFloat / 2 - 1;
85 static constexpr SkIRect kSafeBounds = {-kSafeEdge, -kSafeEdge, kSafeEdge, kSafeEdge};
86 static_assert((kSafeBounds.fRight - kSafeBounds.fLeft) >= 0 &&
87 (kSafeBounds.fBottom - kSafeBounds.fTop) >= 0);
88 if (!picBounds.intersect(kSafeBounds)) {
89 picBounds.setEmpty();
90 }
91 return picBounds;
92}
93
96 , fApproxBytesUsedBySubPictures(0)
97 , fRecord(record) {
98 SkASSERT(this->imageInfo().width() >= 0 && this->imageInfo().height() >= 0);
99}
100
103 , fApproxBytesUsedBySubPictures(0)
104 , fRecord(record) {
105 SkASSERT(this->imageInfo().width() >= 0 && this->imageInfo().height() >= 0);
106}
107
109 this->forgetRecord();
110 fRecord = record;
111 this->resetCanvas(safe_picture_bounds(bounds));
112 SkASSERT(this->imageInfo().width() >= 0 && this->imageInfo().height() >= 0);
113}
114
116 fDrawableList.reset(nullptr);
117 fApproxBytesUsedBySubPictures = 0;
118 fRecord = nullptr;
119}
120
121// To make appending to fRecord a little less verbose.
122template<typename T, typename... Args>
123void SkRecorder::append(Args&&... args) {
124 new (fRecord->append<T>()) T{std::forward<Args>(args)...};
125}
126
127// For methods which must call back into SkNoDrawCanvas.
128#define INHERITED(method, ...) this->SkNoDrawCanvas::method(__VA_ARGS__)
129
130// Use copy() only for optional arguments, to be copied if present or skipped if not.
131// (For most types we just pass by value and let copy constructors do their thing.)
132template <typename T>
133T* SkRecorder::copy(const T* src) {
134 if (nullptr == src) {
135 return nullptr;
136 }
137 return new (fRecord->alloc<T>()) T(*src);
138}
139
140// This copy() is for arrays.
141// It will work with POD or non-POD, though currently we only use it for POD.
142template <typename T>
143T* SkRecorder::copy(const T src[], size_t count) {
144 if (nullptr == src) {
145 return nullptr;
146 }
147 T* dst = fRecord->alloc<T>(count);
148 for (size_t i = 0; i < count; i++) {
149 new (dst + i) T(src[i]);
150 }
151 return dst;
152}
153
154// Specialization for copying strings, using memcpy.
155// This measured around 2x faster for copying code points,
156// but I found no corresponding speedup for other arrays.
157template <>
158char* SkRecorder::copy(const char src[], size_t count) {
159 if (nullptr == src) {
160 return nullptr;
161 }
162 char* dst = fRecord->alloc<char>(count);
163 memcpy(dst, src, count);
164 return dst;
165}
166
167// As above, assuming and copying a terminating \0.
168template <>
169char* SkRecorder::copy(const char* src) {
170 return this->copy(src, strlen(src)+1);
171}
172
174 this->append<SkRecords::DrawPaint>(paint);
175}
176
178 this->append<SkRecords::DrawBehind>(paint);
179}
180
182 size_t count,
183 const SkPoint pts[],
184 const SkPaint& paint) {
185 this->append<SkRecords::DrawPoints>(paint, mode, SkToUInt(count), this->copy(pts, count));
186}
187
189 this->append<SkRecords::DrawRect>(paint, rect);
190}
191
193 this->append<SkRecords::DrawRegion>(paint, region);
194}
195
197 this->append<SkRecords::DrawOval>(paint, oval);
198}
199
201 bool useCenter, const SkPaint& paint) {
202 this->append<SkRecords::DrawArc>(paint, oval, startAngle, sweepAngle, useCenter);
203}
204
206 this->append<SkRecords::DrawRRect>(paint, rrect);
207}
208
209void SkRecorder::onDrawDRRect(const SkRRect& outer, const SkRRect& inner, const SkPaint& paint) {
210 this->append<SkRecords::DrawDRRect>(paint, outer, inner);
211}
212
214 if (!fDrawableList) {
215 fDrawableList = std::make_unique<SkDrawableList>();
216 }
217 fDrawableList->append(drawable);
218 this->append<SkRecords::DrawDrawable>(this->copy(matrix), drawable->getBounds(), fDrawableList->count() - 1);
219}
220
222 this->append<SkRecords::DrawPath>(paint, path);
223}
224
226 const SkSamplingOptions& sampling, const SkPaint* paint) {
227 this->append<SkRecords::DrawImage>(this->copy(paint), sk_ref_sp(image), x, y, sampling);
228}
229
232 SrcRectConstraint constraint) {
233 this->append<SkRecords::DrawImageRect>(this->copy(paint), sk_ref_sp(image), src, dst,
234 sampling, constraint);
235}
236
237void SkRecorder::onDrawImageLattice2(const SkImage* image, const Lattice& lattice, const SkRect& dst,
238 SkFilterMode filter, const SkPaint* paint) {
239 int flagCount = lattice.fRectTypes ? (lattice.fXCount + 1) * (lattice.fYCount + 1) : 0;
240 SkASSERT(lattice.fBounds);
241 this->append<SkRecords::DrawImageLattice>(this->copy(paint), sk_ref_sp(image),
242 lattice.fXCount, this->copy(lattice.fXDivs, lattice.fXCount),
243 lattice.fYCount, this->copy(lattice.fYDivs, lattice.fYCount),
244 flagCount, this->copy(lattice.fRectTypes, flagCount),
245 this->copy(lattice.fColors, flagCount), *lattice.fBounds, dst, filter);
246}
247
249 const SkPaint& paint) {
250 this->append<SkRecords::DrawTextBlob>(paint, sk_ref_sp(blob), x, y);
251}
252
254 this->append<SkRecords::DrawSlug>(paint, sk_ref_sp(slug));
255}
256
258 const sktext::GlyphRunList& glyphRunList, const SkPaint& paint) {
259 sk_sp<SkTextBlob> blob = sk_ref_sp(glyphRunList.blob());
260 if (glyphRunList.blob() == nullptr) {
261 blob = glyphRunList.makeBlob();
262 }
263
264 this->onDrawTextBlob(blob.get(), glyphRunList.origin().x(), glyphRunList.origin().y(), paint);
265}
266
268 fApproxBytesUsedBySubPictures += pic->approximateBytesUsed();
269 this->append<SkRecords::DrawPicture>(this->copy(paint), sk_ref_sp(pic), matrix ? *matrix : SkMatrix::I());
270}
271
273 const SkPaint& paint) {
274 this->append<SkRecords::DrawVertices>(paint,
275 sk_ref_sp(const_cast<SkVertices*>(vertices)),
276 bmode);
277}
278
280 this->append<SkRecords::DrawMesh>(paint, mesh, std::move(blender));
281}
282
283void SkRecorder::onDrawPatch(const SkPoint cubics[12], const SkColor colors[4],
284 const SkPoint texCoords[4], SkBlendMode bmode,
285 const SkPaint& paint) {
286 this->append<SkRecords::DrawPatch>(paint,
287 cubics ? this->copy(cubics, SkPatchUtils::kNumCtrlPts) : nullptr,
288 colors ? this->copy(colors, SkPatchUtils::kNumCorners) : nullptr,
289 texCoords ? this->copy(texCoords, SkPatchUtils::kNumCorners) : nullptr,
290 bmode);
291}
292
293void SkRecorder::onDrawAtlas2(const SkImage* atlas, const SkRSXform xform[], const SkRect tex[],
294 const SkColor colors[], int count, SkBlendMode mode,
295 const SkSamplingOptions& sampling, const SkRect* cull,
296 const SkPaint* paint) {
297 this->append<SkRecords::DrawAtlas>(this->copy(paint),
299 this->copy(xform, count),
300 this->copy(tex, count),
301 this->copy(colors, count),
302 count,
303 mode,
304 sampling,
305 this->copy(cull));
306}
307
309 this->append<SkRecords::DrawShadowRec>(path, rec);
310}
311
313 this->append<SkRecords::DrawAnnotation>(rect, SkString(key), sk_ref_sp(value));
314}
315
318 this->append<SkRecords::DrawEdgeAAQuad>(
319 rect, this->copy(clip, 4), aa, color, mode);
320}
321
323 const SkPoint dstClips[], const SkMatrix preViewMatrices[],
325 SrcRectConstraint constraint) {
326 int totalDstClipCount, totalMatrixCount;
327 SkCanvasPriv::GetDstClipAndMatrixCounts(set, count, &totalDstClipCount, &totalMatrixCount);
328
330 for (int i = 0; i < count; ++i) {
331 setCopy[i] = set[i];
332 }
333
334 this->append<SkRecords::DrawEdgeAAImageSet>(this->copy(paint), std::move(setCopy), count,
335 this->copy(dstClips, totalDstClipCount),
336 this->copy(preViewMatrices, totalMatrixCount), sampling, constraint);
337}
338
340 this->append<SkRecords::Save>();
341}
342
345 for (size_t i = 0; i < rec.fFilters.size(); ++i) {
346 filters[i] = rec.fFilters[i];
347 }
348
349 this->append<SkRecords::SaveLayer>(this->copy(rec.fBounds),
350 this->copy(rec.fPaint),
351 sk_ref_sp(rec.fBackdrop),
352 rec.fSaveLayerFlags,
354 std::move(filters));
356}
357
359 this->append<SkRecords::SaveBehind>(this->copy(subset));
360 return false;
361}
362
364 this->append<SkRecords::Restore>(this->getTotalMatrix());
365}
366
368 this->append<SkRecords::Concat44>(m);
369}
370
372 this->append<SkRecords::SetM44>(m);
373}
374
376 this->append<SkRecords::Scale>(sx, sy);
377}
378
380 this->append<SkRecords::Translate>(dx, dy);
381}
382
384 INHERITED(onClipRect, rect, op, edgeStyle);
385 SkRecords::ClipOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle);
386 this->append<SkRecords::ClipRect>(rect, opAA);
387}
388
390 INHERITED(onClipRRect, rrect, op, edgeStyle);
391 SkRecords::ClipOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle);
392 this->append<SkRecords::ClipRRect>(rrect, opAA);
393}
394
396 INHERITED(onClipPath, path, op, edgeStyle);
397 SkRecords::ClipOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle);
398 this->append<SkRecords::ClipPath>(path, opAA);
399}
400
402 INHERITED(onClipShader, cs, op);
403 this->append<SkRecords::ClipShader>(std::move(cs), op);
404}
405
406void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkClipOp op) {
407 INHERITED(onClipRegion, deviceRgn, op);
408 this->append<SkRecords::ClipRegion>(deviceRgn, op);
409}
410
413 this->append<SkRecords::ResetClip>();
414}
415
417 return nullptr;
418}
int count
Definition: FontMgrTest.cpp:50
#define SkASSERT(cond)
Definition: SkAssert.h:116
SkBlendMode
Definition: SkBlendMode.h:38
SkClipOp
Definition: SkClipOp.h:13
uint32_t SkColor
Definition: SkColor.h:37
constexpr int SK_MaxS32FitsInFloat
static SkPath clip(const SkPath &path, const SkHalfPlane &plane)
Definition: SkPath.cpp:3892
#define INHERITED(method,...)
Definition: SkRecorder.cpp:128
static SkIRect safe_picture_bounds(const SkRect &bounds)
Definition: SkRecorder.cpp:80
sk_sp< T > sk_ref_sp(T *obj)
Definition: SkRefCnt.h:381
static T * SkRef(T *obj)
Definition: SkRefCnt.h:132
SkFilterMode
static void copy(void *dst, const uint8_t *src, int width, int bpp, int deltaSrc, int offset, const SkPMColor ctable[])
Definition: SkSwizzler.cpp:31
constexpr unsigned SkToUInt(S x)
Definition: SkTo.h:30
static SkScalar GetBackdropScaleFactor(const SkCanvas::SaveLayerRec &rec)
Definition: SkCanvasPriv.h:85
static void GetDstClipAndMatrixCounts(const SkCanvas::ImageSetEntry set[], int count, int *totalDstClipCount, int *totalMatrixCount)
SrcRectConstraint
Definition: SkCanvas.h:1541
SaveLayerStrategy
Definition: SkCanvas.h:2263
@ kNoLayer_SaveLayerStrategy
Definition: SkCanvas.h:2265
SkMatrix getTotalMatrix() const
Definition: SkCanvas.cpp:1629
@ kSoft_ClipEdgeStyle
Definition: SkCanvas.h:2337
SkImageInfo imageInfo() const
Definition: SkCanvas.cpp:1206
Definition: SkData.h:25
SkBigPicture::SnapshotArray * newDrawableSnapshot()
Definition: SkRecorder.cpp:62
int count() const
Definition: SkRecorder.h:62
void append(SkDrawable *drawable)
Definition: SkRecorder.cpp:74
SkRect getBounds()
Definition: SkDrawable.cpp:71
Definition: SkM44.h:150
static const SkMatrix & I()
Definition: SkMatrix.cpp:1544
Definition: SkMesh.h:263
void resetCanvas(int w, int h)
Definition: SkPath.h:59
virtual size_t approximateBytesUsed() const =0
T * alloc(size_t count=1)
Definition: SkRecord.h:61
T * append()
Definition: SkRecord.h:72
void didScale(SkScalar, SkScalar) override
Definition: SkRecorder.cpp:375
void onDrawShadowRec(const SkPath &, const SkDrawShadowRec &) override
Definition: SkRecorder.cpp:308
void didTranslate(SkScalar, SkScalar) override
Definition: SkRecorder.cpp:379
void didConcat44(const SkM44 &) override
Definition: SkRecorder.cpp:367
void onDrawDRRect(const SkRRect &, const SkRRect &, const SkPaint &) override
Definition: SkRecorder.cpp:209
void onDrawPicture(const SkPicture *, const SkMatrix *, const SkPaint *) override
Definition: SkRecorder.cpp:267
void onClipShader(sk_sp< SkShader >, SkClipOp) override
Definition: SkRecorder.cpp:401
void onDrawDrawable(SkDrawable *, const SkMatrix *) override
Definition: SkRecorder.cpp:213
void onDrawPatch(const SkPoint cubics[12], const SkColor colors[4], const SkPoint texCoords[4], SkBlendMode, const SkPaint &paint) override
Definition: SkRecorder.cpp:283
void onDrawPaint(const SkPaint &) override
Definition: SkRecorder.cpp:173
void onClipRRect(const SkRRect &rrect, SkClipOp, ClipEdgeStyle) override
Definition: SkRecorder.cpp:389
void onClipRegion(const SkRegion &deviceRgn, SkClipOp) override
Definition: SkRecorder.cpp:406
void onDrawSlug(const sktext::gpu::Slug *slug, const SkPaint &paint) override
Definition: SkRecorder.cpp:253
void onDrawPath(const SkPath &, const SkPaint &) override
Definition: SkRecorder.cpp:221
void onDrawMesh(const SkMesh &, sk_sp< SkBlender >, const SkPaint &) override
Definition: SkRecorder.cpp:279
void onDrawBehind(const SkPaint &) override
Definition: SkRecorder.cpp:177
void onDrawImage2(const SkImage *, SkScalar, SkScalar, const SkSamplingOptions &, const SkPaint *) override
Definition: SkRecorder.cpp:225
void onDrawEdgeAAQuad(const SkRect &, const SkPoint[4], QuadAAFlags, const SkColor4f &, SkBlendMode) override
Definition: SkRecorder.cpp:316
void didSetM44(const SkM44 &) override
Definition: SkRecorder.cpp:371
void onDrawRegion(const SkRegion &, const SkPaint &) override
Definition: SkRecorder.cpp:192
void onDrawVerticesObject(const SkVertices *, SkBlendMode, const SkPaint &) override
Definition: SkRecorder.cpp:272
void onDrawRect(const SkRect &, const SkPaint &) override
Definition: SkRecorder.cpp:188
void onResetClip() override
Definition: SkRecorder.cpp:411
void onDrawImageLattice2(const SkImage *, const Lattice &, const SkRect &, SkFilterMode, const SkPaint *) override
Definition: SkRecorder.cpp:237
void onClipRect(const SkRect &rect, SkClipOp, ClipEdgeStyle) override
Definition: SkRecorder.cpp:383
sk_sp< SkSurface > onNewSurface(const SkImageInfo &, const SkSurfaceProps &) override
Definition: SkRecorder.cpp:416
bool onDoSaveBehind(const SkRect *) override
Definition: SkRecorder.cpp:358
void onDrawGlyphRunList(const sktext::GlyphRunList &glyphRunList, const SkPaint &paint) override
Definition: SkRecorder.cpp:257
void onDrawArc(const SkRect &, SkScalar, SkScalar, bool, const SkPaint &) override
Definition: SkRecorder.cpp:200
void onDrawPoints(PointMode, size_t count, const SkPoint pts[], const SkPaint &) override
Definition: SkRecorder.cpp:181
void onDrawAtlas2(const SkImage *, const SkRSXform[], const SkRect[], const SkColor[], int, SkBlendMode, const SkSamplingOptions &, const SkRect *, const SkPaint *) override
Definition: SkRecorder.cpp:293
void didRestore() override
Definition: SkRecorder.cpp:363
void onDrawTextBlob(const SkTextBlob *blob, SkScalar x, SkScalar y, const SkPaint &paint) override
Definition: SkRecorder.cpp:248
void reset(SkRecord *, const SkRect &bounds)
Definition: SkRecorder.cpp:108
void onDrawImageRect2(const SkImage *, const SkRect &, const SkRect &, const SkSamplingOptions &, const SkPaint *, SrcRectConstraint) override
Definition: SkRecorder.cpp:230
void onDrawEdgeAAImageSet2(const ImageSetEntry[], int count, const SkPoint[], const SkMatrix[], const SkSamplingOptions &, const SkPaint *, SrcRectConstraint) override
Definition: SkRecorder.cpp:322
SkRecorder(SkRecord *, int width, int height)
Definition: SkRecorder.cpp:94
void onDrawAnnotation(const SkRect &, const char[], SkData *) override
Definition: SkRecorder.cpp:312
void forgetRecord()
Definition: SkRecorder.cpp:115
void onClipPath(const SkPath &path, SkClipOp, ClipEdgeStyle) override
Definition: SkRecorder.cpp:395
void onDrawOval(const SkRect &, const SkPaint &) override
Definition: SkRecorder.cpp:196
void willSave() override
Definition: SkRecorder.cpp:339
SaveLayerStrategy getSaveLayerStrategy(const SaveLayerRec &) override
Definition: SkRecorder.cpp:343
void onDrawRRect(const SkRRect &, const SkPaint &) override
Definition: SkRecorder.cpp:205
constexpr size_t size() const
Definition: SkSpan_impl.h:95
int size() const
Definition: SkTDArray.h:138
T * append()
Definition: SkTDArray.h:191
T * get() const
Definition: SkRefCnt.h:303
const SkTextBlob * blob() const
Definition: GlyphRun.h:117
SkPoint origin() const
Definition: GlyphRun.h:114
sk_sp< SkTextBlob > makeBlob() const
Definition: GlyphRun.cpp:88
const Paint & paint
Definition: color_source.cc:38
DlColor color
float SkScalar
Definition: extension.cpp:12
G_BEGIN_DECLS G_MODULE_EXPORT FlValue * args
uint8_t value
double y
double x
sk_sp< const SkImage > atlas
Definition: SkRecords.h:331
int flagCount
Definition: SkRecords.h:274
unsigned useCenter Optional< SkMatrix > matrix
Definition: SkRecords.h:258
Optional< SkRect > bounds
Definition: SkRecords.h:189
PODArray< SkPoint > dstClips
Definition: SkRecords.h:364
sk_sp< const SkImage > image
Definition: SkRecords.h:269
ClipOpAndAA opAA SkRegion region
Definition: SkRecords.h:238
SkRRect rrect
Definition: SkRecords.h:232
SkRect oval
Definition: SkRecords.h:249
sk_sp< SkBlender > blender SkRect rect
Definition: SkRecords.h:350
PODArray< SkMatrix > preViewMatrices
Definition: SkRecords.h:365
SkScalar startAngle
Definition: SkRecords.h:250
SkScalar sweepAngle
Definition: SkRecords.h:251
SkMesh mesh
Definition: SkRecords.h:345
PODArray< SkColor > colors
Definition: SkRecords.h:276
SkSamplingOptions sampling
Definition: SkRecords.h:337
skia_private::AutoTArray< sk_sp< SkImageFilter > > filters TypedMatrix matrix TypedMatrix matrix SkScalar dx
Definition: SkRecords.h:208
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
Definition: switches.h:57
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 mode
Definition: switches.h:228
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not set
Definition: switches.h:76
dst
Definition: cp.py:12
#define T
Definition: precompiler.cc:65
int32_t height
int32_t width
int fYCount
number of y-coordinates
Definition: SkCanvas.h:1617
const SkIRect * fBounds
source bounds to draw from
Definition: SkCanvas.h:1618
const int * fYDivs
y-axis values dividing bitmap
Definition: SkCanvas.h:1614
int fXCount
number of x-coordinates
Definition: SkCanvas.h:1616
const RectType * fRectTypes
array of fill types
Definition: SkCanvas.h:1615
const SkColor * fColors
array of colors
Definition: SkCanvas.h:1619
const int * fXDivs
x-axis values dividing bitmap
Definition: SkCanvas.h:1613
FilterSpan fFilters
Definition: SkCanvas.h:745
const SkRect * fBounds
Definition: SkCanvas.h:740
const SkImageFilter * fBackdrop
Definition: SkCanvas.h:753
const SkPaint * fPaint
Definition: SkCanvas.h:743
SaveLayerFlags fSaveLayerFlags
Definition: SkCanvas.h:763
Definition: SkRect.h:32
bool intersect(const SkIRect &r)
Definition: SkRect.h:513
int32_t fBottom
larger y-axis bounds
Definition: SkRect.h:36
int32_t fTop
smaller y-axis bounds
Definition: SkRect.h:34
void setEmpty()
Definition: SkRect.h:242
int32_t fLeft
smaller x-axis bounds
Definition: SkRect.h:33
int32_t fRight
larger x-axis bounds
Definition: SkRect.h:35
constexpr float y() const
Definition: SkPoint_impl.h:187
constexpr float x() const
Definition: SkPoint_impl.h:181