Home
last modified time | relevance | path

Searched refs:SkRegion (Results 1 – 25 of 45) sorted by relevance

12

/frameworks/base/core/jni/android/graphics/
DRegion.cpp36 static inline SkRegion* GetSkRegion(JNIEnv* env, jobject regionObject) { in GetSkRegion()
38 SkRegion* region = reinterpret_cast<SkRegion*>(regionHandle); in GetSkRegion()
44 return reinterpret_cast<jlong>(new SkRegion); in Region_constructor()
48 SkRegion* region = reinterpret_cast<SkRegion*>(regionHandle); in Region_destructor()
54 SkRegion* dst = reinterpret_cast<SkRegion*>(dstHandle); in Region_setRegion()
55 const SkRegion* src = reinterpret_cast<SkRegion*>(srcHandle); in Region_setRegion()
61 SkRegion* dst = reinterpret_cast<SkRegion*>(dstHandle); in Region_setRect()
68 SkRegion* dst = reinterpret_cast<SkRegion*>(dstHandle); in Region_setPath()
70 const SkRegion* clip = reinterpret_cast<SkRegion*>(clipHandle); in Region_setPath()
78 SkRegion* region = reinterpret_cast<SkRegion*>(regionHandle); in Region_getBounds()
[all …]
DRegion.h26 extern SkRegion* android_graphics_Region_getSkRegion(JNIEnv* env, jobject regionObj);
/frameworks/base/libs/hwui/
DClipArea.cpp162 SkRegion RectangleList::convertToRegion(const SkRegion& clip) const { in convertToRegion()
163 SkRegion rectangleListAsRegion; in convertToRegion()
171 SkRegion rectRegion; in convertToRegion()
173 rectangleListAsRegion.op(rectRegion, SkRegion::kIntersect_Op); in convertToRegion()
219 SkRegion::Op op) { in clipRectWithTransform()
220 if (op == SkRegion::kReplace_Op) mReplaceOpObserved = true; in clipRectWithTransform()
221 if (!mPostViewportClipObserved && op == SkRegion::kIntersect_Op) op = SkRegion::kReplace_Op; in clipRectWithTransform()
236 void ClipArea::clipRegion(const SkRegion& region, SkRegion::Op op) { in clipRegion()
237 if (op == SkRegion::kReplace_Op) mReplaceOpObserved = true; in clipRegion()
238 if (!mPostViewportClipObserved && op == SkRegion::kIntersect_Op) op = SkRegion::kReplace_Op; in clipRegion()
[all …]
DClipArea.h79 SkRegion convertToRegion(const SkRegion& clip) const;
127 ClipRegion(const SkRegion& region) in ClipRegion()
132 SkRegion region;
148 SkRegion::Op op);
149 void clipRegion(const SkRegion& region, SkRegion::Op op);
151 SkRegion::Op op);
157 const SkRegion& getClipRegion() const { in getClipRegion()
182 static void applyTransformToRegion(const Matrix4& transform, SkRegion* region);
186 void rectangleModeClipRectWithTransform(const Rect& r, const mat4* transform, SkRegion::Op op);
190 const mat4* transform, SkRegion::Op op);
[all …]
DSnapshot.h128 void clip(const Rect& localClip, SkRegion::Op op);
135 void clipTransformed(const Rect& r, SkRegion::Op op = SkRegion::kIntersect_Op);
141 void clipRegionTransformed(const SkRegion& region, SkRegion::Op op);
146 void clipPath(const SkPath& path, SkRegion::Op op);
168 const SkRegion& getClipRegion() const { return mClipArea->getClipRegion(); } in getClipRegion()
DDisplayListCanvas.h157 … virtual bool clipRect(float left, float top, float right, float bottom, SkRegion::Op op) override;
158 virtual bool clipPath(const SkPath* path, SkRegion::Op op) override;
159 virtual bool clipRegion(const SkRegion* region, SkRegion::Op op) override;
184 virtual void drawRegion(const SkRegion& region, const SkPaint& paint) override;
300 inline const SkRegion* refRegion(const SkRegion* region) { in refRegion()
305 const SkRegion* cachedRegion = mRegionMap.valueFor(region); in refRegion()
308 std::unique_ptr<const SkRegion> copy(new SkRegion(*region)); in refRegion()
337 DefaultKeyedVector<const SkRegion*, const SkRegion*> mRegionMap;
DRecordingCanvas.h134 … virtual bool clipRect(float left, float top, float right, float bottom, SkRegion::Op op) override;
135 virtual bool clipPath(const SkPath* path, SkRegion::Op op) override;
136 virtual bool clipRegion(const SkRegion* region, SkRegion::Op op) override;
163 virtual void drawRegion(const SkRegion& region, const SkPaint& paint) override;
270 inline const SkRegion* refRegion(const SkRegion* region) { in refRegion()
275 const SkRegion* cachedRegion = mRegionMap.valueFor(region); in refRegion()
278 std::unique_ptr<const SkRegion> copy(new SkRegion(*region)); in refRegion()
307 DefaultKeyedVector<const SkRegion*, const SkRegion*> mRegionMap;
DSkiaCanvasProxy.h91 virtual void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) override;
92 virtual void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) override;
93 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) override;
94 virtual void onClipRegion(const SkRegion&, SkRegion::Op) override;
DCanvasState.h125 bool clipRect(float left, float top, float right, float bottom, SkRegion::Op op);
126 bool clipPath(const SkPath* path, SkRegion::Op op);
127 bool clipRegion(const SkRegion* region, SkRegion::Op op);
DCanvasState.cpp206 bool CanvasState::clipRect(float left, float top, float right, float bottom, SkRegion::Op op) { in clipRect()
212 bool CanvasState::clipPath(const SkPath* path, SkRegion::Op op) { in clipPath()
218 bool CanvasState::clipRegion(const SkRegion* region, SkRegion::Op op) { in clipRegion()
232 clipRect(bounds.left, bounds.top, bounds.right, bounds.bottom, SkRegion::kIntersect_Op); in setClippingOutline()
DSkiaCanvas.cpp107 SkRegion::Op op) override;
108 virtual bool clipPath(const SkPath* path, SkRegion::Op op) override;
109 virtual bool clipRegion(const SkRegion* region, SkRegion::Op op) override;
124 virtual void drawRegion(const SkRegion& region, const SkPaint& paint) override;
213 virtual void clipRect(const SkRect& rect, SkRegion::Op op, bool antialias) { in clipRect()
216 virtual void clipRRect(const SkRRect& rrect, SkRegion::Op op, bool antialias) { in clipRRect()
219 virtual void clipPath(const SkPath& path, SkRegion::Op op, bool antialias) { in clipPath()
493 bool SkiaCanvas::clipRect(float left, float top, float right, float bottom, SkRegion::Op op) { in clipRect()
499 bool SkiaCanvas::clipPath(const SkPath* path, SkRegion::Op op) { in clipPath()
504 bool SkiaCanvas::clipRegion(const SkRegion* region, SkRegion::Op op) { in clipRegion()
[all …]
DSnapshot.cpp86 void Snapshot::clipRegionTransformed(const SkRegion& region, SkRegion::Op op) { in clipRegionTransformed()
91 void Snapshot::clip(const Rect& localClip, SkRegion::Op op) { in clip()
96 void Snapshot::clipPath(const SkPath& path, SkRegion::Op op) { in clipPath()
DDisplayList.h47 class SkRegion; variable
195 LsaVector<std::unique_ptr<const SkRegion>> regions;
DOpenGLRenderer.h319 float right, float bottom, SkRegion::Op op);
320 bool clipPath(const SkPath* path, SkRegion::Op op);
321 bool clipRegion(const SkRegion* region, SkRegion::Op op);
699 void drawRegionRects(const SkRegion& region, const SkPaint& paint, bool dirty = false);
DDisplayListCanvas.cpp196 SkRegion::Op op) { in clipRect()
201 bool DisplayListCanvas::clipPath(const SkPath* path, SkRegion::Op op) { in clipPath()
207 bool DisplayListCanvas::clipRegion(const SkRegion* region, SkRegion::Op op) { in clipRegion()
452 void DisplayListCanvas::drawRegion(const SkRegion& region, const SkPaint& paint) { in drawRegion()
455 SkRegion::Iterator it(region); in drawRegion()
464 SkRegion::Iterator it(region); in drawRegion()
DSkiaCanvasProxy.cpp380 void SkiaCanvasProxy::onClipRect(const SkRect& rect, SkRegion::Op op, ClipEdgeStyle) { in onClipRect()
384 void SkiaCanvasProxy::onClipRRect(const SkRRect& roundRect, SkRegion::Op op, ClipEdgeStyle) { in onClipRRect()
390 void SkiaCanvasProxy::onClipPath(const SkPath& path, SkRegion::Op op, ClipEdgeStyle) { in onClipPath()
394 void SkiaCanvasProxy::onClipRegion(const SkRegion& region, SkRegion::Op op) { in onClipRegion()
/frameworks/base/libs/hwui/tests/unit/
DClipAreaTests.cpp82 SkRegion clip; in TEST()
84 SkRegion rgn(list.convertToRegion(clip)); in TEST()
98 area.clipPathWithTransform(path, &Matrix4::identity(), SkRegion::kIntersect_Op); in TEST()
106 SkRegion clipRegion(area.getClipRegion()); in TEST()
118 area.clipRectWithTransform(expected, &Matrix4::identity(), SkRegion::kReplace_Op); in TEST()
144 area.clipRectWithTransform(Rect(50, 50, 150, 150), &rotate, SkRegion::kIntersect_Op); in TEST()
160 area.clipPathWithTransform(circlePath, &Matrix4::identity(), SkRegion::kReplace_Op); in TEST()
180 area.clipPathWithTransform(circlePath, &Matrix4::identity(), SkRegion::kIntersect_Op); in TEST()
222 area.clipRectWithTransform(Rect(200, 200), &rotate, SkRegion::kIntersect_Op); in TEST()
235 area.clipPathWithTransform(circlePath, &Matrix4::identity(), SkRegion::kReplace_Op); in TEST()
[all …]
DCanvasStateTests.cpp71 state.clipRect(0, 0, 100, 100, SkRegion::kIntersect_Op); in TEST()
74 state.clipRect(10, 10, 200, 200, SkRegion::kIntersect_Op); in TEST()
77 state.clipRect(50, 50, 150, 150, SkRegion::kReplace_Op); in TEST()
91 state.clipRect(0, 0, 200, 200, SkRegion::kIntersect_Op); in TEST()
100 state.clipRect(50, 50, 150, 150, SkRegion::kDifference_Op); in TEST()
111 state.clipPath(&path, SkRegion::kDifference_Op); in TEST()
124 state.clipRect(0, 0, 10, 10, SkRegion::kIntersect_Op); in TEST()
148 state.clipRect(0, 0, 10, 10, SkRegion::kIntersect_Op); in TEST()
DRecordingCanvasTests.cpp60 canvas.clipRect(0, 0, 100, 100, SkRegion::kIntersect_Op); in TEST()
76 canvas.clipRect(0, 0, 100, 100, SkRegion::kIntersect_Op); in TEST()
77 canvas.clipRect(100, 100, 200, 200, SkRegion::kIntersect_Op); in TEST()
93 canvas.drawRegion(SkRegion(SkIRect::MakeWH(200, 200)), emptyPaint); in TEST()
444 canvas.clipRect(10, 20, 190, 180, SkRegion::kIntersect_Op); in TEST()
463 canvas.clipRect(-1000, -1000, 1000, 1000, SkRegion::kReplace_Op); in TEST()
553 canvas.clipRect(0, -20, 200, -20, SkRegion::kIntersect_Op); in TEST()
572 canvas.clipRect(0, 0, 0, 0, SkRegion::kIntersect_Op); // empty clip, reject node in TEST()
625 canvas.clipRect(-100, -100, 300, 300, SkRegion::kIntersect_Op); in TEST()
641 canvas.clipRect(-10, -10, 110, 110, SkRegion::kReplace_Op); in TEST()
[all …]
/frameworks/base/libs/hwui/tests/common/scenes/
DClippingAnimation.cpp37 canvas.clipRect(0, 0, 200, 200, SkRegion::kIntersect_Op); in createContent()
41 canvas.clipRect(0, 0, 200, 200, SkRegion::kIntersect_Op); in createContent()
50 canvas.clipPath(&clipCircle, SkRegion::kIntersect_Op); in createContent()
DRectGridAnimation.cpp40 SkRegion region; in createContent()
43 region.op(xOffset, yOffset, xOffset + 1, yOffset + 1, SkRegion::kUnion_Op); in createContent()
/frameworks/base/libs/hwui/hwui/
DCanvas.h162 SkRegion::Op op = SkRegion::kIntersect_Op) = 0;
163 virtual bool clipPath(const SkPath* path, SkRegion::Op op) = 0;
164 virtual bool clipRegion(const SkRegion* region, SkRegion::Op op) = 0;
184 virtual void drawRegion(const SkRegion& region, const SkPaint& paint) = 0;
/frameworks/native/libs/ui/
DRegion.cpp616 SkRegion sk_lhs; in boolean_operation()
617 SkRegion sk_rhs; in boolean_operation()
618 SkRegion sk_dst; in boolean_operation()
626 SkRegion::kUnion_Op); in boolean_operation()
634 SkRegion::kUnion_Op); in boolean_operation()
637 SkRegion::Op sk_op; in boolean_operation()
639 case op_or: sk_op = SkRegion::kUnion_Op; name="OR"; break; in boolean_operation()
640 case op_xor: sk_op = SkRegion::kUnion_XOR; name="XOR"; break; in boolean_operation()
641 case op_and: sk_op = SkRegion::kIntersect_Op; name="AND"; break; in boolean_operation()
642 case op_nand: sk_op = SkRegion::kDifference_Op; name="NAND"; break; in boolean_operation()
[all …]
/frameworks/base/core/jni/
Dandroid_graphics_Canvas.cpp188 SkRegion::Op op = static_cast<SkRegion::Op>(opHandle); in clipRect()
196 SkRegion::Op op = static_cast<SkRegion::Op>(opHandle); in clipPath()
203 SkRegion* deviceRgn = reinterpret_cast<SkRegion*>(deviceRgnHandle); in clipRegion()
204 SkRegion::Op op = static_cast<SkRegion::Op>(opHandle); in clipRegion()
271 const SkRegion* region = reinterpret_cast<SkRegion*>(regionHandle); in drawRegion()
/frameworks/base/libs/hwui/utils/
DNinePatch.h32 const Res_png_9patch& chunk, const SkPaint* paint, SkRegion** outRegion);

12