CreateCylinderMap


Creates a spatial map for transformations from a cylinder surface to a flat rectangle.

Applications:Inspection of the surface of bottles and other cylindrical objects. The result is used by RemapImage.

Syntax

C++
C#
Python
 
def CreateCylinderMap(
	inImageFormat: ImageFormat,
	inCylinderRectangle: Rectangle2D,
	inMargin: int,
	inCylinderMappingMode: CylinderMappingMode,
	outSpatialMap: SpatialMap,
	/,
	*,
	inCylinderRadiusCorrection: float = 0.0,
	inOpticalAxis: Point2D | None = None,
	inNewWidth: int | None = None,
	inNewHeight: int | None = None,
	inInterpolationMethod: InterpolationMethod = InterpolationMethod.Bilinear,
	outOutputRegion: Region | None = None
)
-> None

Parameters

Name Type Range Default Description
Input value inImageFormat ImageFormat Information about dimensions, depth and pixel type of the image
Input value inCylinderRectangle Rectangle2D Bounding rectangle of the cylinder
Input value inCylinderRadiusCorrection float 0.0 - 0.0 How many pixels the cylinder radius is larger than the visible circle radius
Input value inOpticalAxis Point2D | None None Coordinates of the camera optical axis (Auto = image center)
Input value inNewWidth int | None 1 - None Width of an image created by output spatial map application
Input value inNewHeight int | None 1 - None Height of an image created by output spatial map application
Input value inMargin int 0 - Width of the cylinder extreme points zone excluded from spatial map
Input value inInterpolationMethod InterpolationMethod InterpolationMethod.Bilinear Interpolation method used in extraction of image pixel values
Input value inCylinderMappingMode CylinderMappingMode Determines which pixels of the mapped cylinder have to be within the given rectangle.
Output value outSpatialMap SpatialMap Output spatial map
Output value outOutputRegion Region | None None Pixels set by the spatial map application

Hardware Acceleration

This operation supports automatic parallelization for multicore and multiprocessor systems.