UNPKG

image-js

Version:

Image processing and manipulation in JavaScript

17 lines 611 B
import { getOutputImage } from '../utils/getOutputImage.js'; import { drawMarker } from './drawMarker.js'; /** * Draw markers on the image. * @param image - Image to process. * @param points - Markers center points. * @param options - Draw marker options. * @returns The image with the markers drawing. */ export function drawMarkers(image, points, options = {}) { const newImage = getOutputImage(image, options, { clone: true }); for (const point of points) { drawMarker(newImage, point, { ...options, out: newImage }); } return newImage; } //# sourceMappingURL=drawMarkers.js.map