ClassesClassesClassesClasses | | | | Operators

union1union1Union1union1Union1Union1 (Operator)

Name

union1union1Union1union1Union1Union1 — Return the union of all input regions.

Signature

union1(Region : RegionUnion : : )

Herror union1(const Hobject Region, Hobject* RegionUnion)

Herror T_union1(const Hobject Region, Hobject* RegionUnion)

Herror union1(Hobject Region, Hobject* RegionUnion)

HRegion HRegionArray::Union1() const

void Union1(const HObject& Region, HObject* RegionUnion)

HRegion HRegion::Union1() const

void HOperatorSetX.Union1(
[in] IHUntypedObjectX* Region, [out] IHUntypedObjectX*RegionUnion)

IHRegionX* HRegionX.Union1()

static void HOperatorSet.Union1(HObject region, out HObject regionUnion)

HRegion HRegion.Union1()

Description

union1union1Union1union1Union1Union1 computes the union of all input regions and returns the result in RegionUnionRegionUnionRegionUnionRegionUnionRegionUnionregionUnion.

Parallelization

Parameters

RegionRegionRegionRegionRegionregion (input_object)  region-array objectHRegionHRegionHRegionArrayHRegionXHobject

Regions of which the union is to be computed.

RegionUnionRegionUnionRegionUnionRegionUnionRegionUnionregionUnion (output_object)  region objectHRegionHRegionHRegionHRegionXHobject *

Union of all input regions.

Number of elements: RegionUnion <= Region

Example (HDevelop)

* Union of segmentation results:
threshold(Image,Region1,128,255)
dyn_threshold(Image,Mean,Region2,5,'light')
concat_obj(Region1,Region2,Regions)
union1(Regions,RegionUnion)

Example (C)

/* Union of segmentation results: */
threshold(Image,&Region1,128.0,255.0);
dyn_threshold(Image,Mean,&Region2,5.0,"light");
concat_obj(Region1,Region2,&Regions);
union1(Regions,&RegionUnion);

Example (HDevelop)

* Union of segmentation results:
threshold(Image,Region1,128,255)
dyn_threshold(Image,Mean,Region2,5,'light')
concat_obj(Region1,Region2,Regions)
union1(Regions,RegionUnion)

Example (HDevelop)

* Union of segmentation results:
threshold(Image,Region1,128,255)
dyn_threshold(Image,Mean,Region2,5,'light')
concat_obj(Region1,Region2,Regions)
union1(Regions,RegionUnion)

Example (HDevelop)

* Union of segmentation results:
threshold(Image,Region1,128,255)
dyn_threshold(Image,Mean,Region2,5,'light')
concat_obj(Region1,Region2,Regions)
union1(Regions,RegionUnion)

Example (HDevelop)

* Union of segmentation results:
threshold(Image,Region1,128,255)
dyn_threshold(Image,Mean,Region2,5,'light')
concat_obj(Region1,Region2,Regions)
union1(Regions,RegionUnion)

Complexity

Let F be the sum of all areas of the input regions. Then the runtime complexity is O(log(sqrt(F)) * sqrt(F)).

Result

union1union1Union1union1Union1Union1 always returns 2 (H_MSG_TRUE). The behavior in case of empty input (no regions given) can be set via set_system('no_object_result',<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>) and the behavior in case of an empty input region via set_system('empty_region_result',<Result>)set_system("empty_region_result",<Result>)SetSystem("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

thresholdthresholdThresholdthresholdThresholdThreshold, connectionconnectionConnectionconnectionConnectionConnection, regiongrowingregiongrowingRegiongrowingregiongrowingRegiongrowingRegiongrowing, pouringpouringPouringpouringPouringPouring

Possible Successors

select_shapeselect_shapeSelectShapeselect_shapeSelectShapeSelectShape, disp_regiondisp_regionDispRegiondisp_regionDispRegionDispRegion

Alternatives

union2union2Union2union2Union2Union2

See also

intersectionintersectionIntersectionintersectionIntersectionIntersection, complementcomplementComplementcomplementComplementComplement

Module

Foundation


ClassesClassesClassesClasses | | | | Operators