select_shape_stdselect_shape_stdSelectShapeStdSelectShapeStdselect_shape_std (Operator)
Name
select_shape_stdselect_shape_stdSelectShapeStdSelectShapeStdselect_shape_std — Select regions of a given shape.
Signature
Description
The operator select_shape_stdselect_shape_stdSelectShapeStdSelectShapeStdselect_shape_std compares the shape of the
given regions with default shapes. If the region has a similar shape
it is adopted into the output. Possible values for ShapeShapeShapeshapeshape
are:
- 'max_area'
The largest region is selected.
- 'rectangle1'
The surrounding rectangle parallel to the coordinate axes is
determined via the operator smallest_rectangle1smallest_rectangle1SmallestRectangle1SmallestRectangle1smallest_rectangle1. If the
area difference in percent
is larger than PercentPercentPercentpercentpercent the region is adopted.
- 'rectangle2'
The smallest surrounding rectangle with any orientation is
determined via the operator smallest_rectangle2smallest_rectangle2SmallestRectangle2SmallestRectangle2smallest_rectangle2. If the
area difference in percent
is larger than PercentPercentPercentpercentpercent the region is adopted. Note that as a more
robust alternative the operator select_shapeselect_shapeSelectShapeSelectShapeselect_shape with FeatureFeatureFeaturefeaturefeature
set to 'rectangularity'"rectangularity""rectangularity""rectangularity""rectangularity" can be used instead.
Execution Information
- Multithreading type: reentrant (runs in parallel with non-exclusive operators).
- Multithreading scope: global (may be called from any thread).
- Processed without parallelization.
Parameters
RegionsRegionsRegionsregionsregions (input_object) region(-array) → objectHRegionHObjectHObjectHobject
Input regions to be selected.
SelectedRegionsSelectedRegionsSelectedRegionsselectedRegionsselected_regions (output_object) region(-array) → objectHRegionHObjectHObjectHobject *
Regions with desired shape.
ShapeShapeShapeshapeshape (input_control) string → HTuplestrHTupleHtuple (string) (string) (HString) (char*)
Shape features to be checked.
Default:
'max_area'
"max_area"
"max_area"
"max_area"
"max_area"
List of values:
'max_area'"max_area""max_area""max_area""max_area", 'rectangle1'"rectangle1""rectangle1""rectangle1""rectangle1", 'rectangle2'"rectangle2""rectangle2""rectangle2""rectangle2"
PercentPercentPercentpercentpercent (input_control) real → HTuplefloatHTupleHtuple (real) (double) (double) (double)
Similarity measure.
Default:
70.0
Suggested values:
10.0, 30.0, 50.0, 60.0, 70.0, 80.0, 90.0, 95.0, 100.0
Value range:
0.0
≤
Percent
Percent
Percent
percent
percent
≤
100.0 (lin)
Minimum increment:
0.1
Recommended increment:
10.0
Possible Predecessors
thresholdthresholdThresholdThresholdthreshold,
regiongrowingregiongrowingRegiongrowingRegiongrowingregiongrowing,
connectionconnectionConnectionConnectionconnection,
smallest_rectangle1smallest_rectangle1SmallestRectangle1SmallestRectangle1smallest_rectangle1,
smallest_rectangle2smallest_rectangle2SmallestRectangle2SmallestRectangle2smallest_rectangle2
Alternatives
intersectionintersectionIntersectionIntersectionintersection,
complementcomplementComplementComplementcomplement,
area_centerarea_centerAreaCenterAreaCenterarea_center,
select_shapeselect_shapeSelectShapeSelectShapeselect_shape
See also
smallest_rectangle1smallest_rectangle1SmallestRectangle1SmallestRectangle1smallest_rectangle1,
smallest_rectangle2smallest_rectangle2SmallestRectangle2SmallestRectangle2smallest_rectangle2,
rectangularityrectangularityRectangularityRectangularityrectangularity
Module
Foundation