Home
last modified time | relevance | path

Searched refs:SkRect (Results 1 – 25 of 2779) sorted by relevance

12345678910>>...112

/third_party/flutter/skia/tests/
DQuickRejectTest.cpp47 SkRect r = SkRect::MakeWH(10, 10); in test_layers()
54 SkRect bounds = SkRect::MakeLTRB(50, 50, 70, 70); in test_layers()
56 REPORTER_ASSERT(reporter, true == canvas.quickReject(SkRect::MakeWH(10, 10))); in test_layers()
57 REPORTER_ASSERT(reporter, false == canvas.quickReject(SkRect::MakeWH(60, 60))); in test_layers()
62 SkRect r0 = SkRect::MakeLTRB(-50.0f, -50.0f, 50.0f, 50.0f); in test_quick_reject()
63 SkRect r1 = SkRect::MakeLTRB(-50.0f, 110.0f, 50.0f, 120.0f); in test_quick_reject()
64 SkRect r2 = SkRect::MakeLTRB(110.0f, -50.0f, 120.0f, 50.0f); in test_quick_reject()
65 SkRect r3 = SkRect::MakeLTRB(-120.0f, -50.0f, 120.0f, 50.0f); in test_quick_reject()
66 SkRect r4 = SkRect::MakeLTRB(-50.0f, -120.0f, 50.0f, 120.0f); in test_quick_reject()
67 SkRect r5 = SkRect::MakeLTRB(-120.0f, -120.0f, 120.0f, 120.0f); in test_quick_reject()
[all …]
DRecordDrawTest.cpp63 recorder.drawRect(SkRect::MakeWH(200, 300), SkPaint()); in DEF_TEST()
64 recorder.clipRect(SkRect::MakeWH(100, 200)); in DEF_TEST()
126 static bool sloppy_rect_eq(SkRect a, SkRect b) { in sloppy_rect_eq()
127 SkRect inset(a), outset(a); in sloppy_rect_eq()
139 recorder.clipRect(SkRect::MakeWH(400, 500));
141 recorder.drawRect(SkRect::MakeWH(320, 240), SkPaint());
144 SkAutoTMalloc<SkRect> bounds(record.count());
145 SkRecordFillBounds(SkRect::MakeWH(SkIntToScalar(W), SkIntToScalar(H)), record, bounds);
148 REPORTER_ASSERT(r, sloppy_rect_eq(SkRect::MakeWH(400, 480), bounds[i]));
157 SkRect r1 = { 0, 0, kWidth, kHeight }; in DEF_TEST()
[all …]
/third_party/skia/tests/
DQuickRejectTest.cpp46 SkRect r = SkRect::MakeWH(10, 10); in test_layers()
53 SkRect bounds = SkRect::MakeLTRB(50, 50, 70, 70); in test_layers()
55 REPORTER_ASSERT(reporter, true == canvas.quickReject(SkRect::MakeWH(10, 10))); in test_layers()
56 REPORTER_ASSERT(reporter, false == canvas.quickReject(SkRect::MakeWH(60, 60))); in test_layers()
61 SkRect r0 = SkRect::MakeLTRB(-50.0f, -50.0f, 50.0f, 50.0f); in test_quick_reject()
62 SkRect r1 = SkRect::MakeLTRB(-50.0f, 110.0f, 50.0f, 120.0f); in test_quick_reject()
63 SkRect r2 = SkRect::MakeLTRB(110.0f, -50.0f, 120.0f, 50.0f); in test_quick_reject()
64 SkRect r3 = SkRect::MakeLTRB(-120.0f, -50.0f, 120.0f, 50.0f); in test_quick_reject()
65 SkRect r4 = SkRect::MakeLTRB(-50.0f, -120.0f, 50.0f, 120.0f); in test_quick_reject()
66 SkRect r5 = SkRect::MakeLTRB(-120.0f, -120.0f, 120.0f, 120.0f); in test_quick_reject()
[all …]
DRecordDrawTest.cpp63 recorder.drawRect(SkRect::MakeWH(200, 300), SkPaint()); in DEF_TEST()
64 recorder.clipRect(SkRect::MakeWH(100, 200)); in DEF_TEST()
126 static bool sloppy_rect_eq(SkRect a, SkRect b) { in sloppy_rect_eq()
127 SkRect inset(a), outset(a); in sloppy_rect_eq()
139 recorder.clipRect(SkRect::MakeWH(400, 500));
141 recorder.drawRect(SkRect::MakeWH(320, 240), SkPaint());
144 SkAutoTMalloc<SkRect> bounds(record.count());
145 SkRecordFillBounds(SkRect::MakeWH(SkIntToScalar(W), SkIntToScalar(H)), record, bounds);
148 REPORTER_ASSERT(r, sloppy_rect_eq(SkRect::MakeWH(400, 480), bounds[i]));
157 SkRect r1 = { 0, 0, kWidth, kHeight }; in DEF_TEST()
[all …]
/third_party/skia/modules/sksg/tests/
DSGTest.cpp28 const SkRect& expected_bounds, in check_inval()
29 const SkRect& expected_inval_bounds, in check_inval()
30 const std::vector<SkRect>* expected_damage) { in check_inval()
78 auto r1 = sksg::Rect::Make(SkRect::MakeWH(100, 100)), in inval_test1()
79 r2 = sksg::Rect::Make(SkRect::MakeWH(100, 100)); in inval_test1()
92 SkRect::MakeWH(100, 100), in inval_test1()
109 std::vector<SkRect> damage = { {0, 0, 100, 100}, { 200, 100, 300, 200} }; in inval_test1()
111 SkRect::MakeWH(300, 200), in inval_test1()
112 SkRect::MakeWH(300, 200), in inval_test1()
135 std::vector<SkRect> damage = { {0, 0, 100, 100}, { 200, 100, 300, 200} }; in inval_test1()
[all …]
/third_party/flutter/skia/modules/sksg/tests/
DSGTest.cpp28 const SkRect& expected_bounds, in check_inval()
29 const SkRect& expected_inval_bounds, in check_inval()
30 const std::vector<SkRect>* expected_damage) { in check_inval()
78 auto r1 = sksg::Rect::Make(SkRect::MakeWH(100, 100)), in inval_test1()
79 r2 = sksg::Rect::Make(SkRect::MakeWH(100, 100)); in inval_test1()
92 SkRect::MakeWH(100, 100), in inval_test1()
109 std::vector<SkRect> damage = { {0, 0, 100, 100}, { 200, 100, 300, 200} }; in inval_test1()
111 SkRect::MakeWH(300, 200), in inval_test1()
112 SkRect::MakeWH(300, 200), in inval_test1()
135 std::vector<SkRect> damage = { {0, 0, 100, 100}, { 200, 100, 300, 200} }; in inval_test1()
[all …]
/third_party/skia/gm/
Dbigrect.cpp35 SkRect horiz = SkRect::MakeLTRB(-big, 5, big, 10); in draw_big_rect()
38 SkRect vert = SkRect::MakeLTRB(5, -big, 10, big); in draw_big_rect()
41 SkRect fromLeft = SkRect::MakeLTRB(-big, 20, 17, 25); in draw_big_rect()
44 SkRect fromTop = SkRect::MakeLTRB(20, -big, 25, 17); in draw_big_rect()
47 SkRect fromRight = SkRect::MakeLTRB(28, 20, big, 25); in draw_big_rect()
50 SkRect fromBottom = SkRect::MakeLTRB(20, 28, 25, big); in draw_big_rect()
53 SkRect leftBorder = SkRect::MakeLTRB(-2, -1, 0, 35); in draw_big_rect()
56 SkRect topBorder = SkRect::MakeLTRB(-1, -2, 35, 0); in draw_big_rect()
59 SkRect rightBorder = SkRect::MakeLTRB(34, -1, 36, 35); in draw_big_rect()
62 SkRect bottomBorder = SkRect::MakeLTRB(-1, 34, 35, 36); in draw_big_rect()
[all …]
/third_party/flutter/skia/gm/
Dbigrect.cpp35 SkRect horiz = SkRect::MakeLTRB(-big, 5, big, 10); in draw_big_rect()
38 SkRect vert = SkRect::MakeLTRB(5, -big, 10, big); in draw_big_rect()
41 SkRect fromLeft = SkRect::MakeLTRB(-big, 20, 17, 25); in draw_big_rect()
44 SkRect fromTop = SkRect::MakeLTRB(20, -big, 25, 17); in draw_big_rect()
47 SkRect fromRight = SkRect::MakeLTRB(28, 20, big, 25); in draw_big_rect()
50 SkRect fromBottom = SkRect::MakeLTRB(20, 28, 25, big); in draw_big_rect()
53 SkRect leftBorder = SkRect::MakeLTRB(-2, -1, 0, 35); in draw_big_rect()
56 SkRect topBorder = SkRect::MakeLTRB(-1, -2, 35, 0); in draw_big_rect()
59 SkRect rightBorder = SkRect::MakeLTRB(34, -1, 36, 35); in draw_big_rect()
62 SkRect bottomBorder = SkRect::MakeLTRB(-1, 34, 35, 36); in draw_big_rect()
[all …]
/third_party/flutter/skia/include/utils/
DSkNoDrawCanvas.h41 bool onDoSaveBehind(const SkRect*) override;
44 void onDrawAnnotation(const SkRect&, const char[], SkData*) override {} in onDrawAnnotation() argument
54 void onDrawRect(const SkRect&, const SkPaint&) override {} in onDrawRect() argument
56 void onDrawOval(const SkRect&, const SkPaint&) override {} in onDrawOval() argument
57 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override {} in onDrawArc() argument
61 void onDrawBitmapRect(const SkBitmap&, const SkRect*, const SkRect&, const SkPaint*, in onDrawBitmapRect() argument
64 void onDrawImageRect(const SkImage*, const SkRect*, const SkRect&, const SkPaint*, in onDrawImageRect() argument
66 void onDrawImageNine(const SkImage*, const SkIRect&, const SkRect&, const SkPaint*) override {} in onDrawImageNine() argument
67 void onDrawBitmapNine(const SkBitmap&, const SkIRect&, const SkRect&, in onDrawBitmapNine() argument
69 void onDrawImageLattice(const SkImage*, const Lattice&, const SkRect&, in onDrawImageLattice() argument
[all …]
DSkNWayCanvas.h30 bool onDoSaveBehind(const SkRect*) override;
46 void onDrawRect(const SkRect&, const SkPaint&) override;
48 void onDrawOval(const SkRect&, const SkPaint&) override;
49 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override;
53 void onDrawBitmapRect(const SkBitmap&, const SkRect* src, const SkRect& dst, const SkPaint*,
56 void onDrawImageRect(const SkImage*, const SkRect* src, const SkRect& dst,
58 void onDrawBitmapLattice(const SkBitmap&, const Lattice&, const SkRect&,
60 void onDrawImageLattice(const SkImage*, const Lattice&, const SkRect&, const SkPaint*) override;
61 void onDrawImageNine(const SkImage*, const SkIRect& center, const SkRect& dst,
63 void onDrawBitmapNine(const SkBitmap&, const SkIRect& center, const SkRect& dst,
[all …]
DSkPaintFilterCanvas.h56 void onDrawRect(const SkRect&, const SkPaint&) override;
60 void onDrawOval(const SkRect&, const SkPaint&) override;
61 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override;
64 void onDrawBitmapRect(const SkBitmap&, const SkRect* src, const SkRect& dst, const SkPaint*,
66 void onDrawBitmapNine(const SkBitmap&, const SkIRect& center, const SkRect& dst,
68 void onDrawBitmapLattice(const SkBitmap&, const Lattice&, const SkRect&,
71 void onDrawImageRect(const SkImage*, const SkRect* src, const SkRect& dst,
73 void onDrawImageNine(const SkImage*, const SkIRect& center, const SkRect& dst,
75 void onDrawImageLattice(const SkImage*, const Lattice&, const SkRect&,
87 void onDrawAtlas(const SkImage*, const SkRSXform[], const SkRect[], const SkColor[],
[all …]
/third_party/flutter/skia/include/core/
DSkCanvas.h524 int saveLayer(const SkRect* bounds, const SkPaint* paint);
545 int saveLayer(const SkRect& bounds, const SkPaint* paint) { in saveLayer()
569 int saveLayerAlpha(const SkRect* bounds, U8CPU alpha);
609 SaveLayerRec(const SkRect* bounds, const SkPaint* paint, SaveLayerFlags saveLayerFlags = 0)
627 SaveLayerRec(const SkRect* bounds, const SkPaint* paint, const SkImageFilter* backdrop, in SaveLayerRec()
653 SaveLayerRec(const SkRect* bounds, const SkPaint* paint, const SkImageFilter* backdrop, in SaveLayerRec()
665 const SkRect* fBounds = nullptr;
828 void clipRect(const SkRect& rect, SkClipOp op, bool doAntiAlias);
837 void clipRect(const SkRect& rect, SkClipOp op) { in clipRect()
849 void clipRect(const SkRect& rect, bool doAntiAlias = false) {
[all …]
DSkOverdrawCanvas.h29 void onDrawRect(const SkRect&, const SkPaint&) override;
31 void onDrawOval(const SkRect&, const SkPaint&) override;
32 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override;
38 void onDrawAtlas(const SkImage*, const SkRSXform[], const SkRect[], const SkColor[],
39 int, SkBlendMode, const SkRect*, const SkPaint*) override;
42 void onDrawImageRect(const SkImage*, const SkRect*, const SkRect&, const SkPaint*,
44 void onDrawImageNine(const SkImage*, const SkIRect&, const SkRect&, const SkPaint*) override;
45 void onDrawImageLattice(const SkImage*, const Lattice&, const SkRect&, const SkPaint*) override;
47 void onDrawBitmapRect(const SkBitmap&, const SkRect*, const SkRect&, const SkPaint*,
49 void onDrawBitmapNine(const SkBitmap&, const SkIRect&, const SkRect&, const SkPaint*) override;
[all …]
DSkCanvasVirtualEnforcer.h24 void onDrawRect(const SkRect& rect, const SkPaint& paint) override = 0;
28 void onDrawOval(const SkRect& rect, const SkPaint& paint) override = 0;
29 void onDrawArc(const SkRect& rect, SkScalar startAngle, SkScalar sweepAngle, bool useCenter,
47 void onDrawImageRect(const SkImage* image, const SkRect* src, const SkRect& dst,
49 void onDrawImageNine(const SkImage* image, const SkIRect& center, const SkRect& dst,
52 const SkRect& dst, const SkPaint* paint) override = 0;
57 void onDrawEdgeAAQuad(const SkRect& rect, const SkPoint clip[4], in onDrawEdgeAAQuad()
63 void onDrawEdgeAAQuad(const SkRect& rect, const SkPoint clip[4],
72 void onDrawBitmapRect(const SkBitmap& bitmap, const SkRect* src, const SkRect& dst,
75 void onDrawBitmapNine(const SkBitmap& bitmap, const SkIRect& center, const SkRect& dst,
[all …]
/third_party/skia/src/core/
DSkRectPriv.h29 static SkRect MakeLargeS32() { in MakeLargeS32()
30 SkRect r; in MakeLargeS32()
35 static SkRect MakeLargest() { in MakeLargest()
39 static constexpr SkRect MakeLargestInverted() { in MakeLargestInverted()
43 static void GrowToInclude(SkRect* r, const SkPoint& pt) { in GrowToInclude()
52 static bool FitsInFixed(const SkRect& r) { in FitsInFixed()
63 static SkScalar HalfWidth(const SkRect& r) { in HalfWidth()
67 static SkScalar HalfHeight(const SkRect& r) { in HalfHeight()
74 static bool Subtract(const SkRect& a, const SkRect& b, SkRect* out);
79 static SkRect Subtract(const SkRect& a, const SkRect& b) { in Subtract()
[all …]
/third_party/skia/docs/examples/
DCanvas_saveLayer_4.cpp22 canvas->drawRect(SkRect::MakeLTRB(10, 10, 60, 60), pRed); in draw()
23 canvas->drawRect(SkRect::MakeLTRB(150, 10, 200, 60), pRed); in draw()
25 canvas->drawRect(SkRect::MakeLTRB(30, 10, 80, 60), pSolidBlue); in draw()
26 canvas->drawRect(SkRect::MakeLTRB(170, 10, 220, 60), pThirtyBlue); in draw()
32 canvas->drawRect(SkRect::MakeLTRB(10, 70, 60, 120), pRed); in draw()
33 canvas->drawRect(SkRect::MakeLTRB(150, 70, 200, 120), pRed); in draw()
40 canvas->drawRect(SkRect::MakeLTRB(30, 70, 80, 120), pSolidBlue); in draw()
41 canvas->drawRect(SkRect::MakeLTRB(170, 70, 220, 120), pThirtyBlue); in draw()
50 canvas->drawRect(SkRect::MakeLTRB(10, 130, 60, 180), pRed); in draw()
51 canvas->drawRect(SkRect::MakeLTRB(150, 130, 200, 180), pRed); in draw()
[all …]
DRect_MakeWH.cpp7 SkRect rect1 = SkRect::MakeWH(25, 35); in draw()
8 SkRect rect2 = SkRect::MakeIWH(25, 35); in draw()
9 SkRect rect3 = SkRect::MakeXYWH(0, 0, 25, 35); in draw()
10 SkRect rect4 = SkRect::MakeLTRB(0, 0, 25, 35); in draw()
/third_party/flutter/skia/bench/
DBlurRectsBench.cpp18 BlurRectsBench(SkRect outer, SkRect inner, SkScalar radius) { in BlurRectsBench()
47 SkRect fOuter;
48 SkRect fInner;
56 BlurRectsNinePatchBench(SkRect outer, SkRect inner, SkScalar radius) in BlurRectsNinePatchBench()
66 BlurRectsNonNinePatchBench(SkRect outer, SkRect inner, SkScalar radius) in BlurRectsNonNinePatchBench()
75 DEF_BENCH(return new BlurRectsNinePatchBench(SkRect::MakeXYWH(10, 10, 100, 100),
76 SkRect::MakeXYWH(20, 20, 60, 60),
78 DEF_BENCH(return new BlurRectsNonNinePatchBench(SkRect::MakeXYWH(10, 10, 100, 100),
79 SkRect::MakeXYWH(50, 50, 10, 10),
/third_party/skia/bench/
DBlurRectsBench.cpp18 BlurRectsBench(SkRect outer, SkRect inner, SkScalar radius) { in BlurRectsBench()
47 SkRect fOuter;
48 SkRect fInner;
56 BlurRectsNinePatchBench(SkRect outer, SkRect inner, SkScalar radius) in BlurRectsNinePatchBench()
66 BlurRectsNonNinePatchBench(SkRect outer, SkRect inner, SkScalar radius) in BlurRectsNonNinePatchBench()
75 DEF_BENCH(return new BlurRectsNinePatchBench(SkRect::MakeXYWH(10, 10, 100, 100),
76 SkRect::MakeXYWH(20, 20, 60, 60),
78 DEF_BENCH(return new BlurRectsNonNinePatchBench(SkRect::MakeXYWH(10, 10, 100, 100),
79 SkRect::MakeXYWH(50, 50, 10, 10),
/third_party/flutter/skia/src/core/
DSkRecorder.h44 SkRecorder(SkRecord*, const SkRect& bounds, SkMiniRecorder* = nullptr);
47 void reset(SkRecord*, const SkRect& bounds, DrawPictureMode, SkMiniRecorder* = nullptr);
61 bool onDoSaveBehind(const SkRect*) override;
82 void onDrawRect(const SkRect&, const SkPaint&) override;
84 void onDrawOval(const SkRect&, const SkPaint&) override;
85 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override;
89 void onDrawBitmapRect(const SkBitmap&, const SkRect* src, const SkRect& dst, const SkPaint*,
92 void onDrawImageRect(const SkImage*, const SkRect* src, const SkRect& dst,
94 void onDrawImageNine(const SkImage*, const SkIRect& center, const SkRect& dst,
96 void onDrawBitmapNine(const SkBitmap&, const SkIRect& center, const SkRect& dst,
[all …]
DSkClipStack.h74 Element(const SkRect& rect, const SkMatrix& m, SkClipOp op, bool doAA) { in Element()
110 const SkRect& getDeviceSpaceRect() const { in getDeviceSpaceRect()
150 const SkRect& getBounds() const;
156 bool contains(const SkRect& rect) const;
214 SkRect fFiniteBound;
234 Element(int saveCount, const SkRect& rect, const SkMatrix& m, SkClipOp op, bool doAA) { in Element()
243 void initRect(int saveCount, const SkRect&, const SkMatrix&, SkClipOp, bool doAA);
256 bool rectRectIntersectAllowed(const SkRect& newR, bool newAA) const;
268 inline void combineBoundsDiff(FillCombo combination, const SkRect& prevFinite);
269 inline void combineBoundsXOR(int combination, const SkRect& prevFinite);
[all …]
/third_party/flutter/skia/src/gpu/
DSkGpuDevice.h75 void drawRect(const SkRect& r, const SkPaint& paint) override;
79 void drawOval(const SkRect& oval, const SkPaint& paint) override;
80 void drawArc(const SkRect& oval, SkScalar startAngle, SkScalar sweepAngle,
83 void drawBitmapRect(const SkBitmap&, const SkRect* srcOrNull, const SkRect& dst,
91 void drawAtlas(const SkImage* atlas, const SkRSXform[], const SkRect[],
95 void drawImageRect(const SkImage*, const SkRect* src, const SkRect& dst,
99 const SkRect& dst, const SkPaint& paint) override;
101 const SkRect& dst, const SkPaint& paint) override;
104 const SkRect& dst, const SkPaint&) override;
106 const SkRect& dst, const SkPaint&) override;
[all …]
/third_party/flutter/skia/site/user/api/
DSkRect_Reference.md1 SkRect Reference
5 <a name='SkRect'></a>
10 struct <a href='SkRect_Reference#SkRect'>SkRect</a> {
17 …static constexpr <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeEmpty'>MakeEmpt…
18 …static constexpr <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeWH'>MakeWH</a>(…
19 …static <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeIWH'>MakeIWH</a>(int w, i…
20 …static constexpr <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeSize'>MakeSize<…
21 …static constexpr <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeLTRB'>MakeLTRB<…
23 …static constexpr <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_MakeXYWH'>MakeXYWH<…
25 …static <a href='SkRect_Reference#SkRect'>SkRect</a> <a href='#SkRect_Make'>Make</a>(const <a href=…
[all …]
/third_party/flutter/skia/tools/debugger/
DDebugCanvas.h110 bool onDoSaveBehind(const SkRect*) override;
117 void onDrawAnnotation(const SkRect&, const char[], SkData*) override;
132 void onDrawRect(const SkRect&, const SkPaint&) override;
133 void onDrawOval(const SkRect&, const SkPaint&) override;
134 void onDrawArc(const SkRect&, SkScalar, SkScalar, bool, const SkPaint&) override;
147 const SkRect&,
150 const SkRect* src,
151 const SkRect& dst,
157 const SkRect& dst,
160 const SkRect* src,
[all …]
/third_party/flutter/skia/src/effects/imagefilters/
DSkImageSource.cpp23 SkImageSourceImpl(sk_sp<SkImage> image, const SkRect& srcRect, const SkRect& dstRect, in SkImageSourceImpl()
31 SkRect computeFastBounds(const SkRect& src) const override;
46 SkRect fSrcRect, fDstRect;
55 SkRect rect = image ? SkRect::MakeIWH(image->width(), image->height()) : SkRect::MakeEmpty(); in Make()
60 const SkRect& srcRect, in Make()
61 const SkRect& dstRect, in Make()
82 SkRect src, dst; in CreateProc()
103 SkRect dstRect; in onFilterImage()
106 SkRect bounds = SkRect::MakeIWH(fImage->width(), fImage->height()); in onFilterImage()
155 SkRect SkImageSourceImpl::computeFastBounds(const SkRect& src) const { in computeFastBounds()
[all …]

12345678910>>...112