Back to Aurora Vision Library website

You are here: Start » Function Reference » Computer Vision » Shape Fitting 3D » FitPathToStripe3D_Direct

FitPathToStripe3D_Direct


Header: AVL.h
Namespace: avl
Module: Vision3DStandard

Performs a series of 1D stripe detections in 3D and creates a path from the detected points.

Applications: Tracing of a stripe, whose rough location and shape is known beforehand.

Syntax

C++
C#
 
void avl::FitPathToStripe3D_Direct
(
	const avl::Surface& inSurface,
	const avl::PathFittingField& inFittingField,
	atl::Optional<const avl::CoordinateSystem2D&> inFittingFieldAlignment,
	atl::Optional<float> inScanStep,
	atl::Optional<float> inSamplingStep,
	int inScanWidth,
	const avl::InterpolationMethod::Type inSurfaceInterpolation,
	const avl::StripeScanParams3D& inStripeScanParams,
	avl::Selection::Type inStripeSelection,
	atl::Optional<const avl::LocalBlindness&> inLocalBlindness,
	atl::Optional<int> inMaxProfileGapWidth,
	atl::Optional<int> inMaxPathInterpolationLength,
	atl::Optional<float> inMaxDeviationDelta,
	float inMaxIncompleteness,
	atl::Conditional<atl::Array<avl::Point3D> >& outPath,
	atl::Conditional<atl::Array<avl::Point3D> >& outLeftPath,
	atl::Conditional<atl::Array<avl::Point3D> >& outRightPath,
	atl::Optional<atl::Array<atl::Conditional<avl::SurfaceStripe1D>>&> outStripes = atl::NIL,
	atl::Optional<atl::Conditional<avl::Profile>&> outDeviationProfile = atl::NIL,
	atl::Optional<avl::PathFittingField&> outAlignedFittingField = atl::NIL,
	atl::Optional<atl::Array<avl::Profile>&> outHeightProfiles = atl::NIL,
	atl::Optional<atl::Array<avl::Profile>&> outResponseProfiles = atl::NIL,
	atl::Optional<atl::Conditional<atl::Array<avl::Segment3D> >&> outPathSegments = atl::NIL,
	atl::Array<avl::Segment2D>& diagScanSegments,
	atl::Array<avl::Rectangle2D>& diagSamplingAreas
)

Parameters

Name Type Range Default Description
Input value inSurface const Surface& Surface to fit path to
Input value inFittingField const PathFittingField& Path fitting field
Input value inFittingFieldAlignment Optional<const CoordinateSystem2D&> NIL Adjusts the fitting field to the position of the inspected object
Input value inScanStep Optional<float> 0.0 - 5.0f Optional implicit conversion of the input path to an equidistant one
Input value inSamplingStep Optional<float> 0.0 - NIL Desired distance between consecutive sampling points on the scan segments; if Nil, the bigger of surface X and Y scales is chosen
Input value inScanWidth int 1 - 5 The width of each scan field (in pixels)
Input value inSurfaceInterpolation const InterpolationMethod::Type Bilinear Interpolation method used for extraction of surface points
Input value inStripeScanParams const StripeScanParams3D& StripeScanParams3D ( ProfileInterpolation: Quadratic4 SmoothingStdDev: 1.0f MinMagnitude: 5.0f MaxInnerEdgeMagnitude: Nil MinStripeWidth: 0.0f MaxStripeWidth: Nil StripePolarity: High ) Parameters controlling the stripe extraction process
Input value inStripeSelection Selection::Type Selection mode of stripes
Input value inLocalBlindness Optional<const LocalBlindness&> NIL Defines conditions in which weaker edges can be detected in the vicinity of stronger edges
Input value inMaxProfileGapWidth Optional<int> 0 - 1 Maximal number of consecutive not existing profile points
Input value inMaxPathInterpolationLength Optional<int> 0 - 1 Maximal number of consecutive points not found
Input value inMaxDeviationDelta Optional<float> 0.0 - NIL Maximal difference between deviations of consecutive path points
Input value inMaxIncompleteness float 0.0 - 0.999 0.1f Maximal fraction of stripe points not found
Output value outPath Conditional<Array<Point3D> >& Fitted path or nothing if the fitting failed
Output value outLeftPath Conditional<Array<Point3D> >& Fitted left path
Output value outRightPath Conditional<Array<Point3D> >& Fitted right path
Output value outStripes Optional<Array<Conditional<SurfaceStripe1D>>&> NIL Found stripes
Output value outDeviationProfile Optional<Conditional<Profile>&> NIL Profile of distances between the actual path points and the corresponding reference path points
Output value outAlignedFittingField Optional<PathFittingField&> NIL Fitting field used; in the image coordinate system
Output value outHeightProfiles Optional<Array<Profile>&> NIL Extracted surface height profiles
Output value outResponseProfiles Optional<Array<Profile>&> NIL Profiles of the edge (derivative) operator response
Output value outPathSegments Optional<Conditional<Array<Segment3D> >&> NIL Segments of the fitted path or nothing if the fitting failed
Diagnostic input diagScanSegments Array<Segment2D>& Segments along which the scans were run
Diagnostic input diagSamplingAreas Array<Rectangle2D>& Areas from which the input image is sampled

Optional Outputs

The computation of following outputs can be switched off by passing value atl::NIL to these parameters: outStripes, outDeviationProfile, outAlignedFittingField, outHeightProfiles, outResponseProfiles, outPathSegments.

Read more about Optional Outputs.

Hardware Acceleration

This operation supports automatic parallelization for multicore and multiprocessor systems.

Errors

List of possible exceptions:

Error type Description
DomainError Sampling step set to zero in FitPathToStripe3D.