20 SkRect r = path.getBounds();
27 paint.setColor(0x800000FF);
30 if (path.contains(
x,
y)) {
38 if (canvas->recordingContext() || canvas->recorder()) {
41 *errorMsg =
"This test is for CPU configs only.";
49 for (
int i = 0; i < 4; ++i) {
52 for (
int index = 0; index < (
int) std::size(randoms); ++index) {
56 .quadTo(randoms[2] *
scale, randoms[3] *
scale,
58 .cubicTo(randoms[6] *
scale, randoms[7] *
scale,
constexpr SkColor SK_ColorRED
Type::kYUV Type::kRGBA() int(0.7 *637)
void drawPoint(SkScalar x, SkScalar y, const SkPaint &paint)
void drawPath(const SkPath &path, const SkPaint &paint)
#define DEF_SIMPLE_GM_CAN_FAIL(NAME, CANVAS, ERR_MSG, W, H)
static void test_hittest(SkCanvas *canvas, const SkPath &path)
SkScalar fBottom
larger y-axis bounds
SkScalar fLeft
smaller x-axis bounds
SkScalar fRight
larger x-axis bounds
SkScalar fTop
smaller y-axis bounds