drawImage method

void drawImage (
  1. Image image,
  2. Offset offset,
  3. Paint paint
)

Draws the given Image into the canvas with its top-left corner at the given Offset. The image is composited into the canvas using the given Paint.

Implementation

void drawImage(Image image, Offset offset, Paint paint) {
  // ignore: unnecessary_null_comparison
  assert(image != null); // image is checked on the engine side
  assert(_offsetIsValid(offset));
  assert(paint != null); // ignore: unnecessary_null_comparison
  _drawImage(image, offset.dx, offset.dy, paint._objects, paint._data);
}