chore: upgrade dependencies
This commit is contained in:
45
vendor/gocv.io/x/gocv/imgproc.go
generated
vendored
45
vendor/gocv.io/x/gocv/imgproc.go
generated
vendored
@@ -1568,6 +1568,12 @@ const (
|
||||
|
||||
// InterpolationMax indicates use maximum interpolation.
|
||||
InterpolationMax InterpolationFlags = 7
|
||||
|
||||
// WarpFillOutliers fills all of the destination image pixels. If some of them correspond to outliers in the source image, they are set to zero.
|
||||
WarpFillOutliers = 8
|
||||
|
||||
// WarpInverseMap, inverse transformation.
|
||||
WarpInverseMap = 16
|
||||
)
|
||||
|
||||
// Resize resizes an image.
|
||||
@@ -1649,6 +1655,7 @@ func WarpAffineWithParams(src Mat, dst *Mat, m Mat, sz image.Point, flags Interp
|
||||
}
|
||||
|
||||
// WarpPerspective applies a perspective transformation to an image.
|
||||
// For more parameters please check WarpPerspectiveWithParams.
|
||||
//
|
||||
// For further details, please see:
|
||||
// https://docs.opencv.org/master/da/d54/group__imgproc__transform.html#gaf73673a7e8e18ec6963e3774e6a94b87
|
||||
@@ -1661,6 +1668,24 @@ func WarpPerspective(src Mat, dst *Mat, m Mat, sz image.Point) {
|
||||
C.WarpPerspective(src.p, dst.p, m.p, pSize)
|
||||
}
|
||||
|
||||
// WarpPerspectiveWithParams applies a perspective transformation to an image.
|
||||
//
|
||||
// For further details, please see:
|
||||
// https://docs.opencv.org/master/da/d54/group__imgproc__transform.html#gaf73673a7e8e18ec6963e3774e6a94b87
|
||||
func WarpPerspectiveWithParams(src Mat, dst *Mat, m Mat, sz image.Point, flags InterpolationFlags, borderType BorderType, borderValue color.RGBA) {
|
||||
pSize := C.struct_Size{
|
||||
width: C.int(sz.X),
|
||||
height: C.int(sz.Y),
|
||||
}
|
||||
bv := C.struct_Scalar{
|
||||
val1: C.double(borderValue.B),
|
||||
val2: C.double(borderValue.G),
|
||||
val3: C.double(borderValue.R),
|
||||
val4: C.double(borderValue.A),
|
||||
}
|
||||
C.WarpPerspectiveWithParams(src.p, dst.p, m.p, pSize, C.int(flags), C.int(borderType), bv)
|
||||
}
|
||||
|
||||
// Watershed performs a marker-based image segmentation using the watershed algorithm.
|
||||
//
|
||||
// For further details, please see:
|
||||
@@ -1780,6 +1805,26 @@ func DrawContours(img *Mat, contours PointsVector, contourIdx int, c color.RGBA,
|
||||
C.DrawContours(img.p, contours.p, C.int(contourIdx), sColor, C.int(thickness))
|
||||
}
|
||||
|
||||
// DrawContoursWithParams draws contours outlines or filled contours.
|
||||
//
|
||||
// For further details, please see:
|
||||
// https://docs.opencv.org/master/d6/d6e/group__imgproc__draw.html#ga746c0625f1781f1ffc9056259103edbc
|
||||
//
|
||||
func DrawContoursWithParams(img *Mat, contours PointsVector, contourIdx int, c color.RGBA, thickness int, lineType LineType, hierarchy Mat, maxLevel int, offset image.Point) {
|
||||
sColor := C.struct_Scalar{
|
||||
val1: C.double(c.B),
|
||||
val2: C.double(c.G),
|
||||
val3: C.double(c.R),
|
||||
val4: C.double(c.A),
|
||||
}
|
||||
offsetP := C.struct_Point{
|
||||
x: C.int(offset.X),
|
||||
y: C.int(offset.Y),
|
||||
}
|
||||
|
||||
C.DrawContoursWithParams(img.p, contours.p, C.int(contourIdx), sColor, C.int(thickness), C.int(lineType), hierarchy.p, C.int(maxLevel), offsetP)
|
||||
}
|
||||
|
||||
// Remap applies a generic geometrical transformation to an image.
|
||||
//
|
||||
// For further details, please see:
|
||||
|
||||
Reference in New Issue
Block a user