Lines Matching refs:SkRRect
21 void SkRRect::setOval(const SkRect& oval) { in setOval()
43 void SkRRect::setRectXY(const SkRect& rect, SkScalar xRad, SkScalar yRad) { in setRectXY()
79 void SkRRect::setNinePatch(const SkRect& rect, SkScalar leftRad, SkScalar topRad, in setNinePatch()
167 void SkRRect::setRectRadii(const SkRect& rect, const SkVector radii[4]) { in setRectRadii()
192 bool SkRRect::initializeRect(const SkRect& rect) { in initializeRect()
195 *this = SkRRect(); in initializeRect()
220 bool SkRRect::scaleRadii() { in scaleRadii()
267 bool SkRRect::checkCornerContainment(SkScalar x, SkScalar y) const { in checkCornerContainment()
320 bool SkRRectPriv::IsNearlySimpleCircular(const SkRRect& rr, SkScalar tolerance) { in IsNearlySimpleCircular()
331 bool SkRRectPriv::AllCornersCircular(const SkRRect& rr, SkScalar tolerance) { in AllCornersCircular()
338 bool SkRRect::contains(const SkRect& rect) const { in contains()
360 return radii[SkRRect::kUpperLeft_Corner].fX == radii[SkRRect::kLowerLeft_Corner].fX && in radii_are_nine_patch()
361 radii[SkRRect::kUpperLeft_Corner].fY == radii[SkRRect::kUpperRight_Corner].fY && in radii_are_nine_patch()
362 radii[SkRRect::kUpperRight_Corner].fX == radii[SkRRect::kLowerRight_Corner].fX && in radii_are_nine_patch()
363 radii[SkRRect::kLowerLeft_Corner].fY == radii[SkRRect::kLowerRight_Corner].fY; in radii_are_nine_patch()
367 void SkRRect::computeType() { in computeType()
421 bool SkRRect::transform(const SkMatrix& matrix, SkRRect* dst) const { in transform()
547 void SkRRect::inset(SkScalar dx, SkScalar dy, SkRRect* dst) const { in inset()
565 *dst = SkRRect(); in inset()
584 size_t SkRRect::writeToMemory(void* buffer) const { in writeToMemory()
590 void SkRRectPriv::WriteToBuffer(const SkRRect& rr, SkWBuffer* buffer) { in WriteToBuffer()
592 buffer->write(&rr, SkRRect::kSizeInMemory); in WriteToBuffer()
595 size_t SkRRect::readFromMemory(const void* buffer, size_t length) { in readFromMemory()
602 SkRRect raw; in readFromMemory()
608 bool SkRRectPriv::ReadFromBuffer(SkRBuffer* buffer, SkRRect* rr) { in ReadFromBuffer()
609 if (buffer->available() < SkRRect::kSizeInMemory) { in ReadFromBuffer()
612 SkRRect storage; in ReadFromBuffer()
613 return buffer->read(&storage, SkRRect::kSizeInMemory) && in ReadFromBuffer()
614 (rr->readFromMemory(&storage, SkRRect::kSizeInMemory) == SkRRect::kSizeInMemory); in ReadFromBuffer()
620 SkString SkRRect::dumpToString(bool asHex) const { in dumpToString()
639 void SkRRect::dump(bool asHex) const { SkDebugf("%s\n", this->dumpToString(asHex).c_str()); } in dump()
651 bool SkRRect::isValid() const { in isValid()
724 bool SkRRect::AreRectAndRadiiValid(const SkRect& rect, const SkVector radii[4]) { in AreRectAndRadiiValid()
738 SkRect SkRRectPriv::InnerBounds(const SkRRect& rr) { in InnerBounds()
749 SkVector tl = rr.radii(SkRRect::kUpperLeft_Corner); in InnerBounds()
750 SkVector tr = rr.radii(SkRRect::kUpperRight_Corner); in InnerBounds()
751 SkVector bl = rr.radii(SkRRect::kLowerLeft_Corner); in InnerBounds()
752 SkVector br = rr.radii(SkRRect::kLowerRight_Corner); in InnerBounds()
800 SkRRect SkRRectPriv::ConservativeIntersect(const SkRRect& a, const SkRRect& b) { in ConservativeIntersect()
802 auto getCorner = [](const SkRect& r, SkRRect::Corner corner) -> SkPoint { in ConservativeIntersect()
804 case SkRRect::kUpperLeft_Corner: return {r.fLeft, r.fTop}; in ConservativeIntersect()
805 case SkRRect::kUpperRight_Corner: return {r.fRight, r.fTop}; in ConservativeIntersect()
806 case SkRRect::kLowerLeft_Corner: return {r.fLeft, r.fBottom}; in ConservativeIntersect()
807 case SkRRect::kLowerRight_Corner: return {r.fRight, r.fBottom}; in ConservativeIntersect()
814 auto insideCorner = [](SkRRect::Corner corner, const SkPoint& a, const SkPoint& b) { in ConservativeIntersect()
816 case SkRRect::kUpperLeft_Corner: return a.fX >= b.fX && a.fY >= b.fY; in ConservativeIntersect()
817 case SkRRect::kUpperRight_Corner: return a.fX <= b.fX && a.fY >= b.fY; in ConservativeIntersect()
818 case SkRRect::kLowerRight_Corner: return a.fX <= b.fX && a.fY <= b.fY; in ConservativeIntersect()
819 case SkRRect::kLowerLeft_Corner: return a.fX >= b.fX && a.fY <= b.fY; in ConservativeIntersect()
824 auto getIntersectionRadii = [&](const SkRect& r, SkRRect::Corner corner, SkVector* radii) { in ConservativeIntersect()
873 SkRRect intersection; in ConservativeIntersect()
876 return SkRRect::MakeEmpty(); in ConservativeIntersect()
879 const SkRRect::Corner corners[] = { in ConservativeIntersect()
880 SkRRect::kUpperLeft_Corner, in ConservativeIntersect()
881 SkRRect::kUpperRight_Corner, in ConservativeIntersect()
882 SkRRect::kLowerRight_Corner, in ConservativeIntersect()
883 SkRRect::kLowerLeft_Corner in ConservativeIntersect()
893 return SkRRect::MakeEmpty(); // Resulting intersection is not a rrect in ConservativeIntersect()
902 if (!SkRRect::AreRectAndRadiiValid(intersection.fRect, intersection.fRadii) || in ConservativeIntersect()
904 return SkRRect::MakeEmpty(); in ConservativeIntersect()