draw contours on different canvas
This commit is contained in:
parent
2b3e939c12
commit
a17325be5b
|
|
@ -720,6 +720,11 @@
|
|||
// Find contours
|
||||
cv.findContours(dst, contours, hierarchy, cv.RETR_EXTERNAL, cv.CHAIN_APPROX_SIMPLE);
|
||||
// iterate over contours
|
||||
let contoursColor = new cv.Scalar(0, 0, 255,255);
|
||||
|
||||
cv.drawContours(draw, contours, -1, contoursColor, 1 );
|
||||
cv.drawContours(src, contours, -1, contoursColor, 1 );
|
||||
|
||||
for (let i = 0; i < contours.size(); ++i) {
|
||||
//get contour
|
||||
let cnt = contours.get(i);
|
||||
|
|
|
|||
Loading…
Reference in a new issue