Back to Adaptive Vision Library website

You are here: Start » Function Reference » Image Spatial Transforms » ImageAlongPath

ImageAlongPath


Creates an image from pixels traversed along a path.

Syntax

C++
C#
 
void avl::ImageAlongPath
(
	const avl::Image& inImage,
	const avl::Path& inAxisPath,
	atl::Optional<const avl::CoordinateSystem2D&> inAxisPathAlignment,
	int inScanWidth,
	avl::Axis::Type inAxisType,
	avl::InterpolationMethod::Type inInterpolationMethod,
	avl::Image& outImage,
	atl::Optional<avl::Path&> outAlignedAxisPath = atl::NIL,
	atl::Array<avl::Path>& diagSamplingPoints = dummy(atl::Array<avl::Path>)
)

Parameters

Name Type Range Default Description
inImage const Image& Input image
inAxisPath const Path& Input path
inAxisPathAlignment Optional<const CoordinateSystem2D&> NIL Adjusts the axis path to the position of the inspected object
inScanWidth int 1 - 5 The width of the stripe of pixels along the given path
inAxisType Axis::Type Y Type of axis the transformed axis path will be parallel to
inInterpolationMethod InterpolationMethod::Type Bilinear The interpolation method used to compute pixel brightness in locations of not-integer coordinates
outImage Image& Output image
outAlignedAxisPath Optional<Path&> NIL Input path after transformation (in the image coordinates)
diagSamplingPoints Array<Path>& Array of paths each one containing the sampling points corresponding to one row of the resulting image

Description

The operation transforms the stripe of pixels of width inScanWidth along the inAxisPath in the way that transforms the path into straight segment. Two modes of pixel interpolation are available, the bilinear filtering being more precise and computationally expensive.

The optional parameter inAxisPathAlignment defines the transform to be performed on the inAxisPath so that the resulting path is defined in a new context, e.g. returned by one of Template Matching filters.

Examples

ImageAlongPath performed on the sample image with inScanWidth = 50 and inAxisType = Y. The result was transposed using TransposeImage for clarity.

See Also