1 | initial version |
"scaling" or "transforming" might be the better word ..
no hava here, so no dea if it will work, but , ifyour new image is by1.2 larger in x, and by 1.4 in y direction, you could try:
MatOfPoints contour = ... //(from findContours, i guess)
MatOfPoints scaled = new MatOfPoints();
Core.multiply( contour, new Scalar(1.2, 1.4), scaled );
2 | No.2 Revision |
"scaling" or "transforming" might be the better word ..
no hava java here, so no dea idea if it will work, but , ifyour new image is by1.2 by 1.2 larger in x, and by 1.4 in y direction, you could try:
MatOfPoints contour = ... //(from findContours, i guess)
MatOfPoints scaled = new MatOfPoints();
Core.multiply( contour, new Scalar(1.2, 1.4), scaled );