CreatePerspectiveMap_Points


Creates a perspective transform map from four points denoting a rectangle in the world coordinates.

Applications:Data preprocessing for fast perspective correction. The result is used by RemapImage.

Syntax

C++
C#
Python
 
def CreatePerspectiveMap_Points(
	inImageFormat: ImageFormat,
	inImagePoints: list[Point2D],
	outSpatialMap: SpatialMap,
	outTransformMatrix: Matrix,
	/,
	*,
	inRoi: Region | None = None,
	inTargetPoints: list[Point2D] | None = None,
	inNewSize: Size | None = None,
	inInterpolationMethod: InterpolationMethod = InterpolationMethod.NearestNeighbour
)
-> None

Parameters

Name Type Default Description
Input value inImageFormat ImageFormat
Input value inRoi Region | None None Range of pixels to be processed
Input value inImagePoints list[Point2D] Points define real object plane corners.
Input value inTargetPoints list[Point2D] | None None Points define target plane corners. If NIL then image corners are used starting from (0,0) (Width, 0) (Width, Height), (0, Height)
Input value inNewSize Size | None None New image size after remapping
Input value inInterpolationMethod InterpolationMethod InterpolationMethod.NearestNeighbour Interpolation method used in extraction of image pixel values
Output value outSpatialMap SpatialMap Created SpatialMap with perspective transform
Output value outTransformMatrix Matrix Used transform matrix