/third_party/skia/include/core/ |
D | SkRect.h | 30 int32_t fTop; //!< smaller y-axis bounds member 124 int32_t top() const { return fTop; } in top() 152 int32_t y() const { return fTop; } in y() 155 SkIPoint topLeft() const { return {fLeft, fTop}; } in topLeft() 169 int32_t height() const { return Sk32_can_overflow_sub(fBottom, fTop); } in height() 192 int64_t height64() const { return (int64_t)fBottom - (int64_t)fTop; } in height64() 200 bool isEmpty64() const { return fRight <= fLeft || fBottom <= fTop; } in isEmpty64() 257 fTop = top; in setLTRB() 272 fTop = y; in setXYWH() 279 fTop = 0; in setWH() [all …]
|
/third_party/skia/src/gpu/geometry/ |
D | GrRect.h | 17 int16_t fLeft, fTop, fRight, fBottom; member 44 int height() const { return fBottom - fTop; } in height() 46 bool isEmpty() const { return fLeft >= fRight || fTop >= fBottom; } in isEmpty() 52 fTop = top; in set() 59 fTop = SkToS16(r.fTop); in set() 66 fTop += dy; in offset() 76 SkASSERT(!a.isFinite() || (a.fLeft <= a.fRight && a.fTop <= a.fBottom)); in GrRectsOverlap() 77 SkASSERT(!b.isFinite() || (b.fLeft <= b.fRight && b.fTop <= b.fBottom)); in GrRectsOverlap() 78 return a.fRight > b.fLeft && a.fBottom > b.fTop && b.fRight > a.fLeft && b.fBottom > a.fTop; in GrRectsOverlap() 85 SkASSERT(!a.isFinite() || (a.fLeft <= a.fRight && a.fTop <= a.fBottom)); in GrRectsTouchOrOverlap() [all …]
|
D | GrTriangulator.cpp | 252 fTop->fID, fBottom->fID, other.fTop->fID, other.fBottom->fID); in intersect() 253 if (fTop == other.fTop || fBottom == other.fBottom || in intersect() 254 fTop == other.fBottom || fBottom == other.fTop) { in intersect() 262 fLine, fTop->fPoint, fBottom->fPoint, in intersect() 263 other.fLine, other.fTop->fPoint, other.fBottom->fPoint, in intersect() 282 *alpha = std::max((1.0 - s) * fTop->fAlpha + s * fBottom->fAlpha, in intersect() 283 (1.0 - t) * other.fTop->fAlpha + t * other.fBottom->fAlpha); in intersect() 294 TESS_LOG("removing edge %g -> %g\n", edge->fTop->fID, edge->fBottom->fID); in remove() 317 vertices.append(e->fTop); in emitMonotonePoly() 394 e->fTop->fID, e->fBottom->fID, fID, side == kLeft_Side ? "left" : "right"); in addEdge() [all …]
|
D | GrAATriangulator.cpp | 77 prev->fID, next->fID, e->fEdge->fTop->fID, e->fEdge->fBottom->fID, p.fX, p.fY, in makeEvent() 89 Vertex* top = edge->fEdge->fTop; in makeEvent() 130 if (edge->fEdge->fTop && edge->fEdge->fBottom) { in dump_skel() 132 edge->fEdge->fTop->fID, in dump_skel() 189 Vertex* prev = prevEdge->fWinding == 1 ? prevEdge->fTop : prevEdge->fBottom; in simplifyBoundary() 190 Vertex* next = e->fWinding == 1 ? e->fBottom : e->fTop; in simplifyBoundary() 261 prev->fID, next->fID, fEdge->fEdge->fTop->fID, fEdge->fEdge->fBottom->fID, dest->fID, in apply() 334 e->fTop->fID, e->fBottom->fID); in collapseOverlapRegions() 338 e->fTop->fID, e->fBottom->fID, in collapseOverlapRegions() 340 Vertex* prevVertex = e->fWinding < 0 ? e->fBottom : e->fTop; in collapseOverlapRegions() [all …]
|
/third_party/skia/src/core/ |
D | SkRect.cpp | 17 desc += split + "\t fTop:" + std::to_string(fTop) + "\n"; in dump() 26 std::max(a.fTop, b.fTop), in intersect() 39 if (r.fLeft >= r.fRight || r.fTop >= r.fBottom) { in join() 44 if (fLeft >= fRight || fTop >= fBottom) { in join() 48 if (r.fTop < fTop) fTop = r.fTop; in join() 59 quad[0].set(fLeft, fTop); in toQuad() 60 quad[1].set(fRight, fTop); in toQuad() 122 CHECK_INTERSECT(r.fLeft, r.fTop, r.fRight, r.fBottom, fLeft, fTop, fRight, fBottom); in intersect() 128 CHECK_INTERSECT(a.fLeft, a.fTop, a.fRight, a.fBottom, b.fLeft, b.fTop, b.fRight, b.fBottom); in intersect() 142 fTop = std::min(fTop, r.fTop); in join() [all …]
|
D | SkEdgeClipper.cpp | 16 return bounds.fTop >= clip.fBottom || bounds.fBottom <= clip.fTop; in quick_reject() 100 if (pts[0].fY < clip.fTop) { in chop_quad_in_Y() 101 if (chopMonoQuadAtY(pts, clip.fTop, &t)) { in chop_quad_in_Y() 105 tmp[2].fY = clip.fTop; in chop_quad_in_Y() 106 clamp_ge(tmp[3].fY, clip.fTop); in chop_quad_in_Y() 114 if (pts[i].fY < clip.fTop) { in chop_quad_in_Y() 115 pts[i].fY = clip.fTop; in chop_quad_in_Y() 149 if (pts[2].fY <= clip.fTop || pts[0].fY >= clip.fBottom) { in clipMonoQuad() 286 if (pts[0].fY < clip.fTop) { in chop_cubic_in_Y() 288 chop_mono_cubic_at_y(pts, clip.fTop, tmp); in chop_cubic_in_Y() [all …]
|
D | SkScan.h | 106 xr->fTop = SkIntToFixed(src.fTop); in XRect_set() 117 xr->fTop = SkScalarToFixed(src.fTop); in XRect_set() 126 dst->fTop = SkFixedRoundToInt(xr.fTop); in XRect_round() 136 dst->fTop = SkFixedFloorToInt(xr.fTop); in XRect_roundOut()
|
D | SkLineClipper.cpp | 86 return outer.fLeft <= inner.fLeft && outer.fTop <= inner.fTop && in containsNoEmptyCheck() 105 nestedLT(bounds.fBottom, clip.fTop, bounds.height()) || in IntersectLine() 106 nestedLT(clip.fBottom, bounds.fTop, bounds.height())) { in IntersectLine() 124 if (tmp[index0].fY < clip.fTop) { in IntersectLine() 125 tmp[index0].set(sect_with_horizontal(src, clip.fTop), clip.fTop); in IntersectLine() 189 if (pts[index1].fY <= clip.fTop) { // we're above the clip in ClipLine() 202 if (pts[index0].fY < clip.fTop) { in ClipLine() 203 tmp[index0].set(sect_with_horizontal(pts, clip.fTop), clip.fTop); in ClipLine()
|
D | SkLatticeIter.cpp | 37 latticeBounds.fTop == lattice.fYDivs[0]); in Valid() 43 && valid_divs(lattice.fYDivs, lattice.fYCount, latticeBounds.fTop, latticeBounds.fBottom); in Valid() 140 bool yIsScalable = (yCount > 0 && src.fTop == yDivs[0]); in SkLatticeIter() 151 int yCountScalable = count_scalable_pixels(yDivs, yCount, yIsScalable, src.fTop, src.fBottom); in SkLatticeIter() 162 src.fTop, src.fBottom, dst.fTop, dst.fBottom, yIsScalable); in SkLatticeIter() 227 fSrcY[1] = SkIntToScalar(c.fTop); in SkLatticeIter() 236 fDstY[0] = dst.fTop; in SkLatticeIter() 237 fDstY[1] = dst.fTop + SkIntToScalar(c.fTop); in SkLatticeIter() 247 fDstY[1] = fDstY[0] + (fDstY[3] - fDstY[0]) * c.fTop / (h - c.height()); in SkLatticeIter()
|
D | SkBlitter.cpp | 86 SkScalar partialT = bounds.fTop + 1 - rect.fTop; in blitFatAntiRect() 90 partialT = rect.fBottom - rect.fTop; in blitFatAntiRect() 96 this->blitAntiH(bounds.fLeft, bounds.fTop, alphas, runs); in blitFatAntiRect() 99 this->blitAntiRect(bounds.fLeft, bounds.fTop + 1, bounds.width() - 2, bounds.height() - 2, in blitFatAntiRect() 202 int cy = clip.fTop; in blitMask() 259 const uint8_t* aa = mask.getAddr8(clip.fLeft, clip.fTop); in blitMask() 265 int y = clip.fTop; in blitMask() 295 this->blitRect(cr.fLeft, cr.fTop, cr.width(), cr.height()); in blitRectRegion() 344 return (unsigned)(y - rect.fTop) < (unsigned)rect.height(); in y_in_rect() 418 if (y0 < fClipRect.fTop) { in blitV() [all …]
|
D | SkRectPriv.h | 46 r->fTop = std::min(pt.fY, r->fTop); in GrowToInclude() 53 return SkFitsInFixed(r.fLeft) && SkFitsInFixed(r.fTop) && in FitsInFixed() 58 return SkTFitsIn<int16_t>(r.fLeft) && SkTFitsIn<int16_t>(r.fTop) && in Is16Bit() 68 return SkScalarHalf(r.fBottom) - SkScalarHalf(r.fTop); in HalfHeight()
|
D | SkScan_Path.cpp | 402 shiftedClip.fTop = SkLeftShift(shiftedClip.fTop, shiftEdgesUp); in sk_fill_path() 418 if (rect.fTop < start_y) { in sk_fill_path() 419 rect.fTop = start_y; in sk_fill_path() 426 rect.fTop << shiftEdgesUp, in sk_fill_path() 453 if (!pathContainedInClip && start_y < shiftedClip.fTop) { in sk_fill_path() 454 start_y = shiftedClip.fTop; in sk_fill_path() 484 tmp.fTop = cr.fTop; in sk_blit_above() 485 tmp.fBottom = ir.fTop; in sk_blit_above() 497 tmp.fTop = ir.fBottom; in sk_blit_below() 610 round_down_to_int(src.fTop), in conservative_round_to_int() [all …]
|
D | SkScan_AntiPath.cpp | 70 int fTop; member in BaseSuperBlitter 96 fTop = sectBounds.top(); in BaseSuperBlitter() 97 fCurrIY = fTop - 1; in BaseSuperBlitter() 98 fCurrY = SkLeftShift(fTop, SHIFT) - 1; in BaseSuperBlitter() 166 if (fCurrIY >= fTop) { in flush() 176 fCurrIY = fTop - 1; in flush() 531 SkASSERT(iy >= fMask.fBounds.fTop && iy < fMask.fBounds.fBottom); in blitH() 532 iy -= fMask.fBounds.fTop; // make it relative to 0 in blitH() 683 SkASSERT(SkIntToScalar(ir.fTop) <= path.getBounds().fTop); in SAAFillPath() 684 sk_fill_path(path, clipBounds, &superBlit, ir.fTop, ir.fBottom, SHIFT, containedInClip); in SAAFillPath() [all …]
|
D | SkRegion.cpp | 243 "(%d,%d,%d,%d)", r.fLeft, r.fTop, r.fRight, r.fBottom); in toString() 262 *itop = fBounds.fTop; in count_runtype_values() 347 runs[0] = bounds.fTop; in BuildRectRuns() 425 const RunType* scanline = fRunHead->findScanline(r.fTop); in contains() 510 const RunType* scanline = fRunHead->findScanline(sect.fTop); in intersects() 600 dy = pin_offset_s32(fBounds.fTop, fBounds.fBottom, dy); in translate() 837 , fTop((SkRegionPriv::RunType)top) // just a first guess, we might update this in RgnOper() 860 fTop = (SkRegionPriv::RunType)bottom; // just update our bottom in addSpan() 871 (*fArray)[fStartDst] = fTop; in flush() 887 SkRegionPriv::RunType fTop; member in RgnOper [all …]
|
/third_party/skia/src/pathops/ |
D | SkPathOpsRect.h | 15 double fLeft, fTop, fRight, fBottom; member 19 fTop = std::min(fTop, pt.fY); in add() 26 && approximately_between(fTop, pt.fY, fBottom); in contains() 33 SkASSERT(fTop <= fBottom); in intersects() 35 SkASSERT(r.fTop <= r.fBottom); in intersects() 36 return r.fLeft <= fRight && fLeft <= r.fRight && r.fTop <= fBottom && fTop <= r.fBottom; in intersects() 41 fTop = fBottom = pt.fY; in set() 49 return fBottom - fTop; in height() 73 return fLeft <= fRight && fTop <= fBottom; in valid()
|
D | SkPathOpsBounds.h | 18 && AlmostLessOrEqualUlps(a.fTop, b.fBottom) in Intersects() 19 && AlmostLessOrEqualUlps(b.fTop, a.fBottom); in Intersects() 27 if (top < fTop) fTop = top; in add() 33 add(toAdd.fLeft, toAdd.fTop, toAdd.fRight, toAdd.fBottom); in add() 38 if (pt.fY < fTop) fTop = pt.fY; in add() 45 if (pt.fY < fTop) fTop = SkDoubleToScalar(pt.fY); in add() 53 && AlmostLessOrEqualUlps(fTop, pt.fY) in almostContains() 58 return fLeft <= pt.fX && fTop <= pt.fY && in contains()
|
/third_party/skia/docs/examples/ |
D | Canvas_drawRRect.cpp | 12 rRect.setNinePatch(outer, radii.fLeft, radii.fTop, radii.fRight, radii.fBottom); in draw() 15 canvas->drawLine(outer.fLeft + radii.fLeft, outer.fTop, in draw() 17 canvas->drawLine(outer.fRight - radii.fRight, outer.fTop, in draw() 19 canvas->drawLine(outer.fLeft, outer.fTop + radii.fTop, in draw() 20 outer.fRight, outer.fTop + radii.fTop, paint); in draw()
|
D | Rect_equal_operator.cpp | 10 test.fLeft, test.fTop, test.fRight, test.fBottom, in draw() 12 negZero.fLeft, negZero.fTop, negZero.fRight, negZero.fBottom, in draw() 13 (test.fLeft == negZero.fLeft && test.fTop == negZero.fTop && in draw()
|
D | RRect_Corner.cpp | 15 canvas->drawLine(r.fLeft, r.fTop + rrect.radii(SkRRect::kUpperLeft_Corner).fY, in draw() 16 r.fRight, r.fTop + rrect.radii(SkRRect::kUpperRight_Corner).fY, paint); in draw() 19 canvas->drawLine(r.fLeft + rrect.radii(SkRRect::kUpperLeft_Corner).fX, r.fTop, in draw() 21 canvas->drawLine(r.fRight - rrect.radii(SkRRect::kUpperRight_Corner).fX, r.fTop, in draw()
|
D | RRect_setNinePatch.cpp | 14 canvas->drawLine(r.fLeft, r.fTop + rrect.radii(SkRRect::kUpperLeft_Corner).fY, in draw() 15 r.fRight, r.fTop + rrect.radii(SkRRect::kUpperRight_Corner).fY, paint); in draw() 18 canvas->drawLine(r.fLeft + rrect.radii(SkRRect::kUpperLeft_Corner).fX, r.fTop, in draw() 20 canvas->drawLine(r.fRight - rrect.radii(SkRRect::kUpperRight_Corner).fX, r.fTop, in draw()
|
/third_party/skia/bench/ |
D | RTreeBench.cpp | 86 query.fTop = rand.nextRangeF(0, GENERATE_EXTENTS); in onDraw() 88 query.fBottom = query.fTop + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/2); in onDraw() 102 out.fTop = SkIntToScalar(index / GRID_WIDTH); in make_XYordered_rects() 104 out.fBottom = out.fTop + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/3); in make_XYordered_rects() 110 out.fTop = SkIntToScalar(index % GRID_WIDTH); in make_YXordered_rects() 112 out.fBottom = out.fTop + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/3); in make_YXordered_rects() 119 out.fTop = rand.nextRangeF(0, GENERATE_EXTENTS); in make_random_rects() 121 out.fBottom = out.fTop + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/5); in make_random_rects()
|
/third_party/skia/tests/ |
D | M44Test.cpp | 242 SkV2 tl = map2d(m, {src.fLeft, src.fTop}); in DEF_TEST() 243 SkV2 tr = map2d(m, {src.fRight, src.fTop}); in DEF_TEST() 249 assertEdges(tl.y, bl.y, dst.fTop, dst.fBottom); in DEF_TEST() 250 assertEdges(tr.y, br.y, dst.fTop, dst.fBottom); in DEF_TEST() 259 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(actual.fTop, expected.fTop, e.fTop), in DEF_TEST() 260 "Expected %g == %g", actual.fTop, expected.fTop); in DEF_TEST() 276 SkV4 corners[4] = {{src.fLeft, src.fTop, 0.f, 1.f}, in DEF_TEST() 277 {src.fRight, src.fTop, 0.f, 1.f}, in DEF_TEST() 296 REPORTER_ASSERT(reporter, actual.fTop <= y && y <= actual.fBottom, in DEF_TEST() 298 y, actual.fTop, actual.fBottom); in DEF_TEST() [all …]
|
D | PathOpsAsWindingTest.cpp | 21 path.moveTo(rect.centerX(), rect.fTop); in build_squircle() 22 path.quadTo(rect.fRight, rect.fTop, rect.fRight, rect.centerY()); in build_squircle() 25 path.quadTo(rect.fLeft, rect.fTop, rect.centerX(), rect.fTop); in build_squircle() 34 SkScalar aY14 = rect.fTop + rect.height() * 1 / 4; in build_squircle() 35 SkScalar aY34 = rect.fTop + rect.height() * 3 / 4; in build_squircle() 36 path.moveTo(rect.centerX(), rect.fTop); in build_squircle() 37 path.cubicTo(aX34, rect.fTop, rect.fRight, aY14, rect.fRight, rect.centerY()); in build_squircle() 40 path.cubicTo(rect.fLeft, aY14, aX14, rect.fTop, rect.centerX(), rect.fTop); in build_squircle() 175 for (SkScalar y = rectA.fTop - 1; y <= rectA.fBottom + 1; ++y) { in DEF_TEST()
|
/third_party/skia/src/gpu/tessellate/ |
D | MiddleOutPolygonTriangulator.h | 93 fMiddleOut->fTop = fNewTopVertex; in ~PoppedTriangleStack() 108 Iter begin() const { return {fMiddleOut ? fMiddleOut->fTop : fEnd, fLastPoint}; } in begin() 132 fTop = fVertexStack; 147 StackVertex* endVertex = fTop; in pushVertex() 170 StackVertex* endVertex = std::min(fTop, fVertexStack + 1); in closeAndMove() 189 StackVertex* fTop;
|
/third_party/skia/experimental/sktext/tests/ |
D | SelectableText.cpp | 167 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(firstPosition.fBoundaries.fTop, 0.0f)); in UNIX_ONLY_TEST() 179 …EPORTER_ASSERT(reporter, SkScalarNearlyEqual(lastPosition.fBoundaries.fTop, lastLine.bounds.fTop)); in UNIX_ONLY_TEST() 212 … REPORTER_ASSERT(reporter, SkScalarNearlyEqual(next.fBoundaries.fTop, line.fBounds.fTop)); in UNIX_ONLY_TEST() 218 … REPORTER_ASSERT(reporter, SkScalarNearlyEqual(position.fBoundaries.fTop, next.fBoundaries.fTop)); in UNIX_ONLY_TEST() 253 … REPORTER_ASSERT(reporter, SkScalarNearlyEqual(prev.fBoundaries.fTop, line.fBounds.fTop)); in UNIX_ONLY_TEST() 259 … REPORTER_ASSERT(reporter, SkScalarNearlyEqual(position.fBoundaries.fTop, prev.fBoundaries.fTop)); in UNIX_ONLY_TEST()
|