Skip to content

concat_objConcatObjConcatObjconcat_objconcat_obj🔗

Short description🔗

concat_objConcatObjConcatObjconcat_objconcat_obj — Concatenate two iconic object tuples.

Signature🔗

concat_obj( object Objects1, object Objects2, out object ObjectsConcat )void ConcatObj( const HObject& Objects1, const HObject& Objects2, HObject* ObjectsConcat )static void HOperatorSet.ConcatObj( HObject objects1, HObject objects2, out HObject objectsConcat )def concat_obj( objects_1: HObject, objects_2: HObject ) -> HObject

Herror concat_obj( const Hobject Objects1, const Hobject Objects2, Hobject* ObjectsConcat )

Herror T_concat_obj( const Hobject Objects1, const Hobject Objects2, Hobject* ObjectsConcat )

HObject HObject::ConcatObj( const HObject& Objects2 ) const

HImage HImage::ConcatObj( const HImage& Objects2 ) const

HRegion HRegion::ConcatObj( const HRegion& Objects2 ) const

HXLD HXLD::ConcatObj( const HXLD& Objects2 ) const

HXLDCont HXLDCont::ConcatObj( const HXLDCont& Objects2 ) const

HXLDPoly HXLDPoly::ConcatObj( const HXLDPoly& Objects2 ) const

HXLDPara HXLDPara::ConcatObj( const HXLDPara& Objects2 ) const

HXLDModPara HXLDModPara::ConcatObj( const HXLDModPara& Objects2 ) const

HXLDExtPara HXLDExtPara::ConcatObj( const HXLDExtPara& Objects2 ) const

HObject HObject.ConcatObj( HObject objects2 )

HImage HImage.ConcatObj( HImage objects2 )

HRegion HRegion.ConcatObj( HRegion objects2 )

HXLD HXLD.ConcatObj( HXLD objects2 )

HXLDCont HXLDCont.ConcatObj( HXLDCont objects2 )

HXLDPoly HXLDPoly.ConcatObj( HXLDPoly objects2 )

HXLDPara HXLDPara.ConcatObj( HXLDPara objects2 )

HXLDModPara HXLDModPara.ConcatObj( HXLDModPara objects2 )

HXLDExtPara HXLDExtPara.ConcatObj( HXLDExtPara objects2 )

Description🔗

concat_objConcatObj concatenates the two tuples of iconic objects Objects1objects1objects_1 and Objects2objects2objects_2 into a new tuple of iconic objects ObjectsConcatobjectsConcatobjects_concat. Hence, this tuple contains all the iconic objects of the two input tuples:

ObjectsConcatobjectsConcatobjects_concat = [Objects1objects1objects_1,Objects2objects2objects_2]

In ObjectsConcatobjectsConcatobjects_concat, the objects of Objects1objects1objects_1 are stored first, followed by the objects of Objects2objects2objects_2, i.e., the order of the objects is preserved. Note that only references to the corresponding images and regions are stored in ObjectsConcatobjectsConcatobjects_concat, i.e., no new memory is allocated. Furthermore, this means that modifications of input images, e.g., with set_grayvalSetGrayval, overpaint_grayOverpaintGray, or overpaint_regionOverpaintRegion directly affect the images of the output tuple ObjectsConcatobjectsConcatobjects_concat and vice versa.

concat_objConcatObj should not be confused with union1Union1 or union2Union2, in which regions are merged, i.e., in which the number of objects is modified.

concat_objConcatObj can be used to concatenate objects of different image object types (e.g., images and XLD contours) into a single object. This is only recommended if it is necessary to accumulate in a single object variable, for example, the results of an image processing sequence. It should be noted that the only operators that can handle such object tuples of mixed type are concat_objConcatObj, copy_objCopyObj, select_objSelectObj, and disp_objDispObj.

For a short description of the iconic objects that are available in HALCON see the introduction of chapter Object.

Execution information🔗

Execution information
  • Supports objects on compute devices.

  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

Parameters🔗

Objects1objects1objects_1 (input_object) object(-array) → objectHObjectHObjectHObjectHobject

Object tuple 1.

Objects2objects2objects_2 (input_object) object(-array) → objectHObjectHObjectHObjectHobject

Object tuple 2.

ObjectsConcatobjectsConcatobjects_concat (output_object) object-array → objectHObjectHObjectHObjectHobject *

Concatenated objects.

Example🔗

(C)

/* generate a tuple of a circle and a rectangle */

gen_circle(&Circle,200.0,400.0,23.0)\;
gen_rectangle1(&Rectangle,23.0,44.0,203.0,201.0)\;
concat_obj(Circle,Rectangle,&CircleAndRectangle)\;
disp_region(CircleAndRectangle,WindowHandle)\;

Complexity🔗

Runtime complexity: \(O(|\textrm{Objects1}| + |\textrm{Objects2}|)\);

Memory complexity of the result objects: \(O(|\textrm{Objects1}| + |\textrm{Objects2}|)\)

Result🔗

concat_objConcatObj returns 2 (H_MSG_TRUE) if all objects are contained in the HALCON database. If the input is empty the behavior can be set via set_system(::'no_object_result',<Result>:). If necessary, an exception is raised.

Combinations with other operators🔗

Combinations

See also

count_objCountObj, copy_objCopyObj, select_objSelectObj, disp_objDispObj

Module🔗

Foundation