warpPerspective function
Mat
warpPerspective(
- InputArray src,
- InputArray M,
- (int, int) dsize, {
- OutputArray? dst,
- int flags = INTER_LINEAR,
- int borderMode = BORDER_CONSTANT,
- Scalar? borderValue,
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
Implementation
Mat warpPerspective(
InputArray src,
InputArray M,
(int, int) dsize, {
OutputArray? dst,
int flags = INTER_LINEAR,
int borderMode = BORDER_CONSTANT,
Scalar? borderValue,
}) {
dst ??= Mat.empty();
borderValue ??= Scalar();
cvRun(
() => cimgproc.cv_warpPerspective_1(
src.ref,
dst!.ref,
M.ref,
dsize.cvd.ref,
flags,
borderMode,
borderValue!.ref,
ffi.nullptr,
),
);
return dst;
}