Back to Aurora Vision Library website

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

MeasureObjectWidth3D


Header: AVL.h
Namespace: avl
Module: Vision3DStandard

Measures the width of an object using stripe detection.

Applications: Easy and precise measurement of distances between to straight parallel edges.

Syntax

C++
C#
 
void avl::MeasureObjectWidth3D
(
	const avl::Surface& inSurface,
	const atl::Array<avl::ScanMap>& inMeasurementMap,
	const avl::StripeScanParams3D& inStripeScanParams,
	avl::MeasureObjectMethod::Type inMeasureMethod,
	avl::Selection::Type inStripeSelection,
	atl::Optional<const avl::LocalBlindness&> inLocalBlindness,
	atl::Optional<int> inMaxProfileGapWidth,
	atl::Optional<avl::MEstimator::Type> inOutlierSuppression,
	int inOutlierCount,
	atl::Conditional<float>& outObjectWidth,
	atl::Conditional<avl::Segment2D>& outSegment1,
	atl::Conditional<avl::Segment2D>& outSegment2,
	atl::Optional<atl::Array<atl::Conditional<avl::SurfaceStripe1D>>&> outStripes = atl::NIL,
	atl::Optional<atl::Array<avl::Profile>&> outHeightProfiles = atl::NIL,
	atl::Optional<atl::Array<avl::Profile>&> outResponseProfiles = atl::NIL
)

Parameters

Name Type Range Default Description
Input value inSurface const Surface& Input surface
Input value inMeasurementMap const Array<ScanMap>& Input measurement map
Input value inStripeScanParams const StripeScanParams3D& Parameters controlling the object stripe extraction process
Input value inMeasureMethod MeasureObjectMethod::Type Method used to measure the object
Input value inStripeSelection Selection::Type Selection::​Best Selection mode of edges of the object
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 inOutlierSuppression Optional<MEstimator::Type> NIL Selects a method for ignoring incorrectly detected points
Input value inOutlierCount int 0 - Determines how many outlying points are rejected before the width is measured
Output value outObjectWidth Conditional<float>& Width of the object
Output value outSegment1 Conditional<Segment2D>& First edge of the object
Output value outSegment2 Conditional<Segment2D>& Second edge of the object
Output value outStripes Optional<Array<Conditional<SurfaceStripe1D>>&> NIL Detected stripes
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

Optional Outputs

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

Read more about Optional Outputs.

Errors

List of possible exceptions:

Error type Description
DomainError Invalid MeasurementMap in MeasureObjectWidth3D function. Use CreateSurfaceMeasurementMap function to create it properly.