HALCON Reference Manual 10.0.2
Table of Contents / Regions / Features ClassesClassesClasses | | | Operators

eccentricityeccentricityeccentricityEccentricityEccentricity (Operator)

Name

eccentricityeccentricityeccentricityEccentricityEccentricity — Shape features derived from the ellipse parameters.

Signature

eccentricity(Regions : : : Anisometry, Bulkiness, StructureFactor)

Herror eccentricity(const Hobject Regions, double* Anisometry, double* Bulkiness, double* StructureFactor)

Herror T_eccentricity(const Hobject Regions, Htuple* Anisometry, Htuple* Bulkiness, Htuple* StructureFactor)

Herror eccentricity(Hobject Regions, double* Anisometry, double* Bulkiness, double* StructureFactor)

Herror eccentricity(Hobject Regions, HTuple* Anisometry, HTuple* Bulkiness, HTuple* StructureFactor)

double HRegion::Eccentricity(double* Bulkiness, double* StructureFactor) const

HTuple HRegionArray::Eccentricity(HTuple* Bulkiness, HTuple* StructureFactor) const

void HOperatorSetX.Eccentricity(
[in] IHUntypedObjectX* Regions, [out] VARIANT* Anisometry, [out] VARIANT* Bulkiness, [out] VARIANT* StructureFactor)

VARIANT HRegionX.Eccentricity(
[out] VARIANT* Bulkiness, [out] VARIANT* StructureFactor)

static void HOperatorSet.Eccentricity(HObject regions, out HTuple anisometry, out HTuple bulkiness, out HTuple structureFactor)

HTuple HRegion.Eccentricity(out HTuple bulkiness, out HTuple structureFactor)

double HRegion.Eccentricity(out double bulkiness, out double structureFactor)

Description

The operator eccentricityeccentricityeccentricityEccentricityEccentricity calculates three shape features derived from the geometric moments.

Definition: If the ellipse radii Ra, Rb and the area A of the
            region are given (see elliptic_axiselliptic_axiselliptic_axisEllipticAxisEllipticAxis),
            the following applies:

   AnisometryAnisometryAnisometryAnisometryanisometry = Ra / Rb

   BulkinessBulkinessBulkinessBulkinessbulkiness = pi Ra Rb / A

   StructureFactorStructureFactorStructureFactorStructureFactorstructureFactor = AnisometryAnisometryAnisometryAnisometryanisometry * BulkinessBulkinessBulkinessBulkinessbulkiness - 1

 

Attention

It should be noted that, like for all region-moments-based operators, the region's pixels are regarded as mathematical, infinitely small points that are represented by the center of the pixels (see the documentation of elliptic_axiselliptic_axiselliptic_axisEllipticAxisEllipticAxis). This can lead to non-empty regions that have RbRbRbRbrb = 0. In these cases, the output features that require a division by RbRbRbRbrb are set to 0. In particular, regions that contain a single point or regions whose points lie exactly on a straight line (e.g., one pixel high horizontal regions or one pixel wide vertical regions) have an anisometry of 0.

Parallelization

Parameters

RegionsRegionsRegionsRegionsregions (input_object)  region(-array) objectHRegionHRegionHRegionXHobject

Region(s) to be examined.

AnisometryAnisometryAnisometryAnisometryanisometry (output_control)  real(-array) HTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double)

Shape feature (in case of a circle = 1.0).

Assertion: Anisometry >= 1.0

BulkinessBulkinessBulkinessBulkinessbulkiness (output_control)  real(-array) HTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double)

Calculated shape feature.

StructureFactorStructureFactorStructureFactorStructureFactorstructureFactor (output_control)  real(-array) HTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double)

Calculated shape feature.

Complexity

If F is the area of the region the mean runtime complexity is O(sqrt(F)).

Result

The operator eccentricityeccentricityeccentricityEccentricityEccentricity returns the value 2 (H_MSG_TRUE) if the input is not empty. The behavior in case of empty input (no input regions available) is set via the operator set_system('no_object_result',<Result>)set_system("no_object_result",<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>). The behavior in case of empty region (the region is the empty set) is set via set_system('empty_region_result',<Result>)set_system("empty_region_result",<Result>)set_system("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>). If necessary an exception is raised.

Possible Predecessors

thresholdthresholdthresholdThresholdThreshold, regiongrowingregiongrowingregiongrowingRegiongrowingRegiongrowing, connectionconnectionconnectionConnectionConnection

See also

elliptic_axiselliptic_axiselliptic_axisEllipticAxisEllipticAxis, moments_region_2ndmoments_region_2ndmoments_region_2ndMomentsRegion2ndMomentsRegion2nd, select_shapeselect_shapeselect_shapeSelectShapeSelectShape, area_centerarea_centerarea_centerAreaCenterAreaCenter

Module

Foundation


Table of Contents / Regions / Features ClassesClassesClasses | | | Operators
HALCON Reference Manual 10.0.2 Copyright © 1996-2011 MVTec Software GmbH