Applies a perspective transformation to an image.
Namespace: OpenCvSharp.CPlusPlus
Assembly: OpenCvSharp.CPlusPlus (in OpenCvSharp.CPlusPlus.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public static void WarpPerspective( InputArray src, OutputArray dst, InputArray m, Size dsize, Interpolation flags = Interpolation.Linear, BorderType borderMode = BorderType.Constant, Nullable<Scalar> borderValue = null )
Parameters
- src
- Type: OpenCvSharp.CPlusPlusInputArray
input image. - dst
- Type: OpenCvSharp.CPlusPlusOutputArray
output image that has the size dsize and the same type as src. - m
- Type: OpenCvSharp.CPlusPlusInputArray
3x3 transformation matrix. - dsize
- Type: OpenCvSharp.CPlusPlusSize
size of the output image. - flags (Optional)
- Type: OpenCvSharpInterpolation
combination of interpolation methods (INTER_LINEAR or INTER_NEAREST) and the optional flag WARP_INVERSE_MAP, that sets M as the inverse transformation (dst -> src). - borderMode (Optional)
- Type: OpenCvSharpBorderType
pixel extrapolation method (BORDER_CONSTANT or BORDER_REPLICATE). - borderValue (Optional)
- Type: SystemNullableScalar
value used in case of a constant border; by default, it equals 0.
See Also