| 120 | } |
| 121 | |
| 122 | void HitTestContext::drawImage(std::shared_ptr<Image> image, const SamplingOptions&, |
| 123 | const MCState& state, const Fill& fill) { |
| 124 | // Images are always checked against their bounding box. |
| 125 | Point local = {}; |
| 126 | if (!GetLocalPoint(state.matrix, deviceX, deviceY, &local)) { |
| 127 | return; |
| 128 | } |
| 129 | auto imageBounds = Rect::MakeWH(image->width(), image->height()); |
| 130 | if (imageBounds.contains(local.x, local.y) && checkClipAndFill(state.clip, fill, local)) { |
| 131 | hit = true; |
| 132 | } |
| 133 | } |
| 134 | |
| 135 | void HitTestContext::drawImageRect(std::shared_ptr<Image>, const Rect&, const Rect& dstRect, |
| 136 | const SamplingOptions&, const MCState& state, const Fill& fill, |
nothing calls this directly
no test coverage detected