Skip to content
This repository was archived by the owner on Jul 26, 2025. It is now read-only.

Commit 8a82333

Browse files
committed
feat: add setBlendedVisiblePixlel to drawPoints
1 parent 697c4a8 commit 8a82333

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/draw/drawPoints.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { Mask } from '../Mask';
33
import { Point } from '../utils/geometry/points';
44
import { getDefaultColor } from '../utils/getDefaultColor';
55
import { getOutputImage, maskToOutputMask } from '../utils/getOutputImage';
6+
import { setBlendedVisiblePixel } from '../utils/setBlendedVisiblePixel';
67
import checkProcessable from '../utils/validators/checkProcessable';
78
import { validateColor } from '../utils/validators/validators';
89

@@ -61,10 +62,11 @@ export function drawPoints(
6162
});
6263

6364
for (const point of points) {
64-
newImage.setVisiblePixel(
65+
setBlendedVisiblePixel(
66+
newImage,
6567
Math.round(origin.column + point.column),
6668
Math.round(origin.row + point.row),
67-
color,
69+
{ color },
6870
);
6971
}
7072

0 commit comments

Comments
 (0)