Home
last modified time | relevance | path

Searched refs:SkIRect (Results 1 – 25 of 1123) sorted by relevance

12345678910>>...45

/external/skia/tests/
DRegionTest.cpp14 static void Union(SkRegion* rgn, const SkIRect& rect) { in Union()
26 Union(&r, SkIRect::MakeXYWH(0, 0, 1, 1)); in test_fromchrome()
27 TEST_NO_INTERSECT(r, SkIRect::MakeXYWH(0, 0, 0, 0)); in test_fromchrome()
28 TEST_INTERSECT(r, SkIRect::MakeXYWH(0, 0, 2, 2)); in test_fromchrome()
29 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, 0, 2, 2)); in test_fromchrome()
30 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, -1, 2, 2)); in test_fromchrome()
31 TEST_INTERSECT(r, SkIRect::MakeXYWH(0, -1, 2, 2)); in test_fromchrome()
32 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, -1, 3, 3)); in test_fromchrome()
34 Union(&r, SkIRect::MakeXYWH(0, 0, 3, 3)); in test_fromchrome()
35 Union(&r, SkIRect::MakeXYWH(10, 0, 3, 3)); in test_fromchrome()
[all …]
DImageFilterTest.cpp116 FilterList(sk_sp<SkImageFilter> input, const SkIRect* cropRect = nullptr) { in FilterList()
163 SkIRect leftSideCropRect = SkIRect::MakeXYWH(0, 0, 32, 64); in FilterList()
166 SkIRect rightSideCropRect = SkIRect::MakeXYWH(32, 0, 32, 64); in FilterList()
206 recordingCanvas->drawRect(SkRect::Make(SkIRect::MakeXYWH(10, 10, 30, 20)), greenPaint); in FilterList()
248 FixedBoundsImageFilter(const SkIRect& bounds) in FixedBoundsImageFilter()
259 SkIRect onFilterBounds(const SkIRect&, const SkMatrix&, in onFilterBounds() argument
260 MapDirection, const SkIRect*) const override { in onFilterBounds()
264 SkIRect fBounds;
316 const SkIRect* cropRect) { in make_grayscale()
327 static sk_sp<SkImageFilter> make_blue(sk_sp<SkImageFilter> input, const SkIRect* cropRect) { in make_blue()
[all …]
/external/skqp/tests/
DRegionTest.cpp14 static void Union(SkRegion* rgn, const SkIRect& rect) { in Union()
26 Union(&r, SkIRect::MakeXYWH(0, 0, 1, 1)); in test_fromchrome()
27 TEST_NO_INTERSECT(r, SkIRect::MakeXYWH(0, 0, 0, 0)); in test_fromchrome()
28 TEST_INTERSECT(r, SkIRect::MakeXYWH(0, 0, 2, 2)); in test_fromchrome()
29 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, 0, 2, 2)); in test_fromchrome()
30 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, -1, 2, 2)); in test_fromchrome()
31 TEST_INTERSECT(r, SkIRect::MakeXYWH(0, -1, 2, 2)); in test_fromchrome()
32 TEST_INTERSECT(r, SkIRect::MakeXYWH(-1, -1, 3, 3)); in test_fromchrome()
34 Union(&r, SkIRect::MakeXYWH(0, 0, 3, 3)); in test_fromchrome()
35 Union(&r, SkIRect::MakeXYWH(10, 0, 3, 3)); in test_fromchrome()
[all …]
/external/skia/src/core/
DSkImageFilter.cpp58 SkIRect SkImageFilter::filterBounds(const SkIRect& src, const SkMatrix& ctm, in filterBounds()
59 MapDirection direction, const SkIRect* inputRect) const { in filterBounds()
65 skif::LayerSpace<SkIRect> targetOutput(src); in filterBounds()
67 skif::LayerSpace<SkIRect> outputCrop = mapping.paramToLayer( in filterBounds()
73 return SkIRect::MakeEmpty(); in filterBounds()
76 skif::LayerSpace<SkIRect> content(inputRect ? *inputRect : src); in filterBounds()
77 return SkIRect(as_IFB(this)->onGetInputLayerBounds(mapping, targetOutput, content)); in filterBounds()
80 skif::LayerSpace<SkIRect> content(src); in filterBounds()
81 skif::LayerSpace<SkIRect> output = as_IFB(this)->onGetOutputLayerBounds(mapping, content); in filterBounds()
83 SkIRect dst; in filterBounds()
[all …]
DSkRasterClip.h19 SkIRect fBounds = SkIRect::MakeEmpty();
23 const SkIRect* fClipRestrictionRect = nullptr;
25 inline void applyClipRestriction(SkRegion::Op op, SkIRect* bounds) { in applyClipRestriction()
46 const SkIRect& getBounds() const { return fBounds; } in getBounds()
48 void setEmpty() { this->setRect(SkIRect::MakeEmpty()); } in setEmpty()
49 void setRect(const SkIRect& r) { in setRect()
54 void setDeviceClipRestriction(const SkIRect* rect) { in setDeviceClipRestriction()
61 void opRect(const SkRect&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
62 void opRRect(const SkRRect&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
63 void opPath(const SkPath&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
[all …]
DSkImageFilter_Base.h73 skif::LayerSpace<SkIRect> getInputBounds(
74 const skif::Mapping& mapping, const skif::DeviceSpace<SkIRect>& desiredOutput,
101 skif::DeviceSpace<SkIRect> getOutputBounds(
105 SkIRect filterNodeBounds(const SkIRect& srcRect, const SkMatrix& ctm, in filterNodeBounds()
106 MapDirection dir, const SkIRect* inputRect) const { in filterNodeBounds()
167 void applyTo(const SkIRect& imageBounds, const SkMatrix& matrix, bool embiggen,
168 SkIRect* cropped) const;
220 virtual SkIRect onFilterBounds(const SkIRect&, const SkMatrix& ctm,
221 MapDirection, const SkIRect* inputRect) const;
222 virtual SkIRect onFilterNodeBounds(const SkIRect&, const SkMatrix& ctm,
[all …]
/external/skqp/src/core/
DSkRasterClip.h18 SkIRect fBounds;
19 const SkIRect* fClipRestrictionRect;
21 inline void applyClipRestriction(SkRegion::Op op, SkIRect* bounds) { in applyClipRestriction()
31 SkConservativeClip() : fBounds(SkIRect::MakeEmpty()), fClipRestrictionRect(nullptr) {} in SkConservativeClip()
35 const SkIRect& getBounds() const { return fBounds; } in getBounds()
38 void setRect(const SkIRect& r) { fBounds = r; } in setRect()
39 void setDeviceClipRestriction(const SkIRect* rect) { in setDeviceClipRestriction()
43 void opRect(const SkRect&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
44 void opRRect(const SkRRect&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
45 void opPath(const SkPath&, const SkMatrix&, const SkIRect& limit, SkRegion::Op, bool isAA);
[all …]
DSkImageFilter.cpp32 void SkImageFilter::CropRect::applyTo(const SkIRect& imageBounds, in applyTo()
35 SkIRect* cropped) const { in applyTo()
40 SkIRect devICropR = devCropR.roundOut(); in applyTo()
169 const SkIRect srcSubset = fUsesSrcInput ? src->subset() : SkIRect::MakeWH(0, 0); in filterImage()
196 SkIRect SkImageFilter::filterBounds(const SkIRect& src, const SkMatrix& ctm, in filterBounds()
197 MapDirection direction, const SkIRect* inputRect) const { in filterBounds()
199 SkIRect bounds = this->onFilterNodeBounds(src, ctm, direction, inputRect); in filterBounds()
203 SkIRect bounds = this->onFilterBounds(src, ctm, direction, nullptr); in filterBounds()
205 SkIRect dst; in filterBounds()
243 const SkIRect& bounds, in DrawWithFP()
[all …]
DSkGpuBlurUtils.cpp27 static void scale_irect_roundout(SkIRect* rect, float xScale, float yScale) { in scale_irect_roundout()
34 static void scale_irect(SkIRect* rect, int xScale, int yScale) { in scale_irect()
45 static void shrink_irect_by_2(SkIRect* rect, bool xAxis, bool yAxis) { in shrink_irect_by_2()
75 const SkIRect& dstRect, in convolve_gaussian_1d()
108 const SkIRect& srcBounds, in convolve_gaussian_2d()
155 const SkIRect& srcRect, in convolve_gaussian()
160 SkIRect* contentRect, in convolve_gaussian()
189 SkIRect dstRect = SkIRect::MakeWH(srcRect.width(), srcRect.height()); in convolve_gaussian()
198 SkIRect midRect = *contentRect, leftRect, rightRect; in convolve_gaussian()
200 SkIRect topRect, bottomRect; in convolve_gaussian()
[all …]
/external/skqp/site/user/api/
DSkIRect_Reference.md1 SkIRect Reference
5 <a name='SkIRect'></a>
10 struct <a href='SkIRect_Reference#SkIRect'>SkIRect</a> {
17 …static constexpr <a href='SkIRect_Reference#SkIRect'>SkIRect</a> <a href='#SkIRect_MakeEmpty'>Make…
18 …static constexpr <a href='SkIRect_Reference#SkIRect'>SkIRect</a> <a href='#SkIRect_MakeWH'>MakeWH<…
19 …static constexpr <a href='SkIRect_Reference#SkIRect'>SkIRect</a> <a href='#SkIRect_MakeSize'>MakeS…
20 …static constexpr <a href='SkIRect_Reference#SkIRect'>SkIRect</a> <a href='#SkIRect_MakeLTRB'>MakeL…
22 …static constexpr <a href='SkIRect_Reference#SkIRect'>SkIRect</a> <a href='#SkIRect_MakeXYWH'>MakeX…
37 …=</a>(const <a href='SkIRect_Reference#SkIRect'>SkIRect</a>& a, const <a href='SkIRect_Reference#S…
38 …=</a>(const <a href='SkIRect_Reference#SkIRect'>SkIRect</a>& a, const <a href='SkIRect_Reference#S…
[all …]
/external/skia/include/core/
DSkRegion.h59 explicit SkRegion(const SkIRect& rect);
158 const SkIRect& getBounds() const { return fBounds; } in getBounds()
201 bool setRect(const SkIRect& rect);
214 bool setRects(const SkIRect rects[], int count);
254 bool intersects(const SkIRect& rect) const;
285 bool contains(const SkIRect& other) const;
303 bool quickContains(const SkIRect& r) const { in quickContains()
320 bool quickReject(const SkIRect& rect) const { in quickReject()
322 !SkIRect::Intersects(fBounds, rect); in quickReject()
334 !SkIRect::Intersects(fBounds, rgn.fBounds); in quickReject()
[all …]
DSkRect.h28 struct SK_API SkIRect { struct
41 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeEmpty() { in MakeEmpty() argument
42 return SkIRect{0, 0, 0, 0}; in MakeEmpty()
52 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeWH(int32_t w, int32_t h) { in MakeWH() argument
53 return SkIRect{0, 0, w, h}; in MakeWH()
62 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeSize(const SkISize& size) { in MakeSize() argument
63 return SkIRect{0, 0, size.fWidth, size.fHeight}; in MakeSize()
74 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakePtSize(SkIPoint pt, SkISize size) { in MakePtSize() argument
87 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeLTRB(int32_t l, int32_t t, in MakeLTRB() argument
89 return SkIRect{l, t, r, b}; in MakeLTRB()
[all …]
/external/skqp/include/core/
DSkRegion.h63 explicit SkRegion(const SkIRect& rect);
154 const SkIRect& getBounds() const { return fBounds; } in getBounds()
189 bool setRect(const SkIRect& rect);
214 bool setRects(const SkIRect rects[], int count);
248 bool intersects(const SkIRect& rect) const;
273 bool contains(const SkIRect& other) const;
289 bool quickContains(const SkIRect& r) const { in quickContains()
322 bool quickReject(const SkIRect& rect) const { in quickReject()
324 !SkIRect::Intersects(fBounds, rect); in quickReject()
336 !SkIRect::Intersects(fBounds, rgn.fBounds); in quickReject()
[all …]
DSkImageFilter.h60 Context(const SkMatrix& ctm, const SkIRect& clipBounds, SkImageFilterCache* cache, in Context()
69 const SkIRect& clipBounds() const { return fClipBounds; } in clipBounds()
85 SkIRect fClipBounds;
115 void applyTo(const SkIRect& imageBounds, const SkMatrix& matrix, bool embiggen,
116 SkIRect* cropped) const;
166 SkIRect filterBounds(const SkIRect& src, const SkMatrix& ctm,
167 MapDirection, const SkIRect* inputRect = nullptr) const;
172 const SkIRect& bounds,
352 virtual SkIRect onFilterBounds(const SkIRect&, const SkMatrix& ctm,
353 MapDirection, const SkIRect* inputRect) const;
[all …]
DSkRect.h37 struct SK_API SkIRect { struct
50 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeEmpty() { in MakeEmpty() argument
51 return SkIRect{0, 0, 0, 0}; in MakeEmpty()
61 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeWH(int32_t w, int32_t h) { in MakeWH() argument
62 return SkIRect{0, 0, w, h}; in MakeWH()
71 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeSize(const SkISize& size) { in MakeSize() argument
72 return SkIRect{0, 0, size.fWidth, size.fHeight}; in MakeSize()
84 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeLTRB(int32_t l, int32_t t, in MakeLTRB() argument
86 return SkIRect{l, t, r, b}; in MakeLTRB()
98 static constexpr SkIRect SK_WARN_UNUSED_RESULT MakeXYWH(int32_t x, int32_t y, in MakeXYWH() argument
[all …]
/external/skia/src/effects/imagefilters/
DSkMatrixConvolutionImageFilter.cpp59 SkIRect onFilterNodeBounds(const SkIRect&, const SkMatrix& ctm,
60 MapDirection, const SkIRect* inputRect) const override;
79 const SkIRect& rect,
80 const SkIRect& bounds) const;
85 const SkIRect& rect,
86 const SkIRect& bounds) const;
90 const SkIRect& rect,
91 const SkIRect& bounds) const;
95 const SkIRect& rect,
96 const SkIRect& bounds) const;
[all …]
DSkTileImageFilter.cpp31 SkIRect onFilterBounds(const SkIRect& src, const SkMatrix& ctm,
32 MapDirection, const SkIRect* inputRect) const override;
33 SkIRect onFilterNodeBounds(const SkIRect&, const SkMatrix& ctm,
34 MapDirection, const SkIRect* inputRect) const override;
108 const SkIRect dstIRect = dstRect.roundOut(); in onFilterImage()
115 SkIRect srcIRect; in onFilterImage()
118 const SkIRect inputBounds = SkIRect::MakeWH(input->width(), input->height()); in onFilterImage()
120 if (!SkIRect::Intersects(srcIRect, inputBounds)) { in onFilterImage()
172 SkIRect SkTileImageFilter::onFilterNodeBounds( in onFilterNodeBounds()
173 const SkIRect& src, const SkMatrix& ctm, MapDirection dir, const SkIRect* inputRect) const { in onFilterNodeBounds()
[all …]
DSkBlendImageFilter.cpp41 SkIRect onFilterBounds(const SkIRect&, const SkMatrix& ctm,
42 MapDirection, const SkIRect* inputRect) const override;
50 const SkIRect& bounds) const;
55 void drawForeground(SkCanvas* canvas, SkSpecialImage*, const SkIRect&) const;
114 SkIRect foregroundBounds = SkIRect::MakeEmpty(); in onFilterImage()
116 foregroundBounds = SkIRect::MakeXYWH(foregroundOffset.x(), foregroundOffset.y(), in onFilterImage()
120 SkIRect srcBounds = SkIRect::MakeEmpty(); in onFilterImage()
122 srcBounds = SkIRect::MakeXYWH(backgroundOffset.x(), backgroundOffset.y(), in onFilterImage()
131 SkIRect bounds; in onFilterImage()
170 SkIRect SkBlendImageFilter::onFilterBounds(const SkIRect& src, in onFilterBounds()
[all …]
/external/skqp/docs/
DSkIRect_Reference.bmh5 #Struct SkIRect
11 SkIRect holds four 32-bit integer coordinates describing the upper and
12 lower bounds of a rectangle. SkIRect may be created from outer bounds or
13 from position, width, and height. SkIRect describes an area; if its right
43 #Method static constexpr SkIRect MakeEmpty()
50 SkIRect rect = SkIRect::MakeEmpty();
72 #Method static constexpr SkIRect MakeWH(int32_t w, int32_t h)
79 SkIRect rect1 = SkIRect::MakeWH(25, 35);
80 SkIRect rect2 = SkIRect::MakeSize({25, 35});
81 SkIRect rect3 = SkIRect::MakeXYWH(0, 0, 25, 35);
[all …]
/external/skia/gm/
Dimagemakewithfilter.cpp40 static void show_bounds(SkCanvas* canvas, const SkIRect* clip, const SkIRect* inSubset, in show_bounds()
41 const SkIRect* outSubset) { in show_bounds()
42 const SkIRect* rects[] { clip, inSubset, outSubset }; in show_bounds()
60 typedef sk_sp<SkImageFilter> (*FilterFactory)(sk_sp<SkImage> auxImage, const SkIRect* cropRect);
62 static sk_sp<SkImageFilter> color_filter_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in color_filter_factory()
69 static sk_sp<SkImageFilter> blur_filter_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in blur_filter_factory()
73 static sk_sp<SkImageFilter> drop_shadow_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in drop_shadow_factory()
77 static sk_sp<SkImageFilter> offset_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in offset_factory()
81 static sk_sp<SkImageFilter> dilate_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in dilate_factory()
85 static sk_sp<SkImageFilter> erode_factory(sk_sp<SkImage> auxImage, const SkIRect* cropRect) { in erode_factory()
[all …]
/external/skia/docs/examples/
DIRect_MakeWH.cpp7 SkIRect rect1 = SkIRect::MakeWH(25, 35); in draw()
8 SkIRect rect2 = SkIRect::MakeSize({25, 35}); in draw()
9 SkIRect rect3 = SkIRect::MakeXYWH(0, 0, 25, 35); in draw()
10 SkIRect rect4 = SkIRect::MakeLTRB(0, 0, 25, 35); in draw()
/external/skqp/src/gpu/
DGrWindowRectangles.h26 const SkIRect* data() const;
31 SkIRect& addWindow(const SkIRect& window) { return this->addWindow() = window; } in addWindow()
32 SkIRect& addWindow();
45 SkIRect fLocalWindows[kNumLocalWindows]; // If fCount <= kNumLocalWindows.
51 Rec(const SkIRect* windows, int numWindows) { in Rec()
53 memcpy(fData, windows, sizeof(SkIRect) * numWindows); in Rec()
57 SkIRect fData[kMaxWindows];
60 inline const SkIRect* GrWindowRectangles::data() const { in data()
73 memcpy(fLocalWindows, that.fLocalWindows, fCount * sizeof(SkIRect));
86 SkIRect* windows; in makeOffset()
[all …]
/external/skqp/include/effects/
DSkMatrixConvolutionImageFilter.h86 SkIRect onFilterNodeBounds(const SkIRect&, const SkMatrix& ctm,
87 MapDirection, const SkIRect* inputRect) const override;
105 const SkIRect& rect,
106 const SkIRect& bounds) const;
111 const SkIRect& rect,
112 const SkIRect& bounds) const;
116 const SkIRect& rect,
117 const SkIRect& bounds) const;
121 const SkIRect& rect,
122 const SkIRect& bounds) const;
/external/skia/src/gpu/
DGrWindowRectangles.h26 const SkIRect* data() const;
31 SkIRect& addWindow(const SkIRect& window) { return this->addWindow() = window; } in addWindow()
32 SkIRect& addWindow();
44 SkIRect fLocalWindow; // If fCount <= 1
50 Rec(const SkIRect* windows, int numWindows) { in Rec()
52 memcpy(fData, windows, sizeof(SkIRect) * numWindows); in Rec()
56 SkIRect fData[kMaxWindows];
59 inline const SkIRect* GrWindowRectangles::data() const { in data()
85 SkIRect* windows; in makeOffset()
98 inline SkIRect& GrWindowRectangles::addWindow() { in addWindow()
[all …]
DGrClipStack.h41 GrClipStack(const SkIRect& deviceBounds, const SkMatrixProvider* matrixProvider, bool forceAA);
71 void replaceClip(const SkIRect& rect);
78 SkIRect getConservativeBounds() const override;
107 const SkIRect& outerBounds() const { return fOuterBounds; } in outerBounds()
117 const SkIRect& innerBounds() const { return fInnerBounds; } in innerBounds()
145 void simplify(const SkIRect& deviceBounds, bool forceAA);
157 SkIRect fInnerBounds;
158 SkIRect fOuterBounds;
175 Mask(const SaveRecord& current, const SkIRect& bounds);
183 const SkIRect& bounds() const { return fBounds; } in bounds()
[all …]

12345678910>>...45