drawBoundingBoxOutline function
void
drawBoundingBoxOutline({})
Draw the axis-aligned outline of a BoundingBox transformed by a linear scale + offset. Use a stroked Paint for an outline, or a filled one to tint the interior.
Implementation
void drawBoundingBoxOutline({
required Canvas canvas,
required BoundingBox bbox,
required double scaleX,
required double scaleY,
required double offsetX,
required double offsetY,
required Paint paint,
}) {
canvas.drawRect(
Rect.fromLTRB(
bbox.left * scaleX + offsetX,
bbox.top * scaleY + offsetY,
bbox.right * scaleX + offsetX,
bbox.bottom * scaleY + offsetY,
),
paint,
);
}