Back to Aurora Vision Library website

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

ImageAlongArc


Header: AVL.h
Namespace: avl
Module: FoundationBasic

Creates an image from pixels traversed along an arc.

Applications: E.g. "Unwrapping" of object contours, so that they appear as 1D structures on the output image.

Syntax

C++
C#
 
void avl::ImageAlongArc
(
	const avl::Image& inImage,
	const avl::Arc2D& inAxisArc,
	atl::Optional<const avl::CoordinateSystem2D&> inAxisArcAlignment,
	int inScanWidth,
	avl::Axis::Type inAxisType,
	avl::InterpolationMethod::Type inInterpolationMethod,
	atl::Optional<const avl::Pixel&> inBorderColor,
	avl::Image& outImage,
	atl::Optional<avl::Arc2D&> outAlignedAxisArc = atl::NIL,
	atl::Array<avl::Path>& diagSamplingPoints = atl::Dummy<atl::Array<avl::Path> >()
)

Parameters

Name Type Range Default Description
Input value inImage const Image& Input image
Input value inAxisArc const Arc2D& Input arc
Input value inAxisArcAlignment Optional<const CoordinateSystem2D&> NIL Adjusts the axis arc to the position of the inspected object
Input value inScanWidth int 1 - 5 The width of the stripe of pixels along the given arc
Input value inAxisType Axis::Type Y Type of axis the transformed axis arc will be parallel to
Input value inInterpolationMethod InterpolationMethod::Type Bilinear The interpolation method used to compute pixel brightness in locations of not-integer coordinates
Input value inBorderColor Optional<const Pixel&> NIL Color of pixel outside image. If inBorderColor = NIL then algorithm repeats color of boarder.
Output value outImage Image& Output image
Output value outAlignedAxisArc Optional<Arc2D&> NIL Input arc after transformation (in the image coordinates)
Diagnostic input diagSamplingPoints Array<Path>& Array of paths each one containing the sampling points corresponding to one row of the resulting image

Optional Outputs

The computation of following outputs can be switched off by passing value atl::NIL to these parameters: outAlignedAxisArc.

Read more about Optional Outputs.

Description

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

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

Examples

ImageAlongArc performed on the sample image with inScanWidth = 50 and inAxisType = X.

See Also

  • ImageProfileAlongPath – Creates a series of segments across the input path, measures the average pixel intensity on each of the segments, and creates the final profile from those values.
  • ImageAlongPath – Creates an image from pixels traversed along a path.