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

mirror_regionmirror_regionmirror_regionMirrorRegionMirrorRegion (Operator)

Name

mirror_regionmirror_regionmirror_regionMirrorRegionMirrorRegion — Reflect a region about an axis.

Signature

mirror_region(Region : RegionMirror : Mode, WidthHeight : )

Herror mirror_region(const Hobject Region, Hobject* RegionMirror, const char* Mode, const Hlong WidthHeight)

Herror T_mirror_region(const Hobject Region, Hobject* RegionMirror, const Htuple Mode, const Htuple WidthHeight)

Herror mirror_region(Hobject Region, Hobject* RegionMirror, const HTuple& Mode, const HTuple& WidthHeight)

HRegion HRegion::MirrorRegion(const HTuple& Mode, const HTuple& WidthHeight) const

HRegionArray HRegionArray::MirrorRegion(const HTuple& Mode, const HTuple& WidthHeight) const

void HOperatorSetX.MirrorRegion(
[in] IHUntypedObjectX* Region, [out] IHUntypedObjectX*RegionMirror, [in] VARIANT Mode, [in] VARIANT WidthHeight)

IHRegionX* HRegionX.MirrorRegion(
[in] BSTR Mode, [in] Hlong WidthHeight)

static void HOperatorSet.MirrorRegion(HObject region, out HObject regionMirror, HTuple mode, HTuple widthHeight)

HRegion HRegion.MirrorRegion(string mode, int widthHeight)

Description

mirror_regionmirror_regionmirror_regionMirrorRegionMirrorRegion reflects a region about one of three possible axes. If ModeModeModeModemode is set to 'row'"row""row""row""row", it is reflected about the horizontal axis, if ModeModeModeModemode is set to 'column'"column""column""column""column", about the vertical axis, and if ModeModeModeModemode is set to 'diagonal'"diagonal""diagonal""diagonal""diagonal", about the main diagonal x=y.

For ModeModeModeModemode = 'row'"row""row""row""row" or 'column'"column""column""column""column" the parameter WidthHeightWidthHeightWidthHeightWidthHeightwidthHeight specifies two times the coordinate of the axis of symmetry. Hence, if RegionRegionRegionRegionregion has been extracted from an image and should be mirrored in a way such as if it had been extracted from a mirrored version of this image, WidthHeightWidthHeightWidthHeightWidthHeightwidthHeight corresponds to one of the dimensions of this image (according to ModeModeModeModemode). If ModeModeModeModemode = 'diagonal'"diagonal""diagonal""diagonal""diagonal", the parameter WidthHeightWidthHeightWidthHeightWidthHeightwidthHeight is not used.

Parallelization

Parameters

RegionRegionRegionRegionregion (input_object)  region(-array) objectHRegionHRegionHRegionXHobject

Region(s) to be reflected.

RegionMirrorRegionMirrorRegionMirrorRegionMirrorregionMirror (output_object)  region(-array) objectHRegionHRegionHRegionXHobject *

Reflected region(s).

Number of elements: RegionMirror == Region

ModeModeModeModemode (input_control)  string HTupleHTupleVARIANTHtuple (string) (string) (char*) (BSTR) (char*)

Axis of symmetry.

Default value: 'row' "row" "row" "row" "row"

List of values: 'column'"column""column""column""column", 'row'"row""row""row""row", 'diagonal'"diagonal""diagonal""diagonal""diagonal"

WidthHeightWidthHeightWidthHeightWidthHeightwidthHeight (input_control)  integer HTupleHTupleVARIANTHtuple (integer) (int / long) (Hlong) (Hlong) (Hlong)

Twice the coordinate of the axis of symmetry.

Default value: 512

Suggested values: 128, 256, 512, 525, 768, 1024

Typical range of values: 1 ≤ WidthHeight WidthHeight WidthHeight WidthHeight widthHeight ≤ 1024 (lin)

Minimum increment: 1

Recommended increment: 1

Restriction: WidthHeight > 0

Example (C)

read_image(&Image,"monkey");
threshold(Image,&Seg,128.0,255.0);
mirror_region(Seg,&Mirror,"row",512);
disp_region(Mirror,WindowHandle);

Possible Predecessors

thresholdthresholdthresholdThresholdThreshold, connectionconnectionconnectionConnectionConnection, regiongrowingregiongrowingregiongrowingRegiongrowingRegiongrowing, pouringpouringpouringPouringPouring

Possible Successors

select_shapeselect_shapeselect_shapeSelectShapeSelectShape, disp_regiondisp_regiondisp_regionDispRegionDispRegion

Alternatives

affine_trans_regionaffine_trans_regionaffine_trans_regionAffineTransRegionAffineTransRegion

See also

zoom_regionzoom_regionzoom_regionZoomRegionZoomRegion

Module

Foundation


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