You are here: Start » Function Reference » Document

Region Basics

Icon Name Description / Applications Modules
CreateBoxBorderRegion CreateBoxBorderRegion

Creates a frame-shaped region with given parameters.

FoundationLite
CreateBoxRegion CreateBoxRegion

Creates a rectangular region corresponding to a given box.

FoundationLite
CreateCircleRegion CreateCircleRegion

Creates a circular region corresponding to a given circle.

FoundationLite
CreateCrossRegion CreateCrossRegion

Creates a cross-shaped region with given parameters.

FoundationLite
CreateEllipseRegion CreateEllipseRegion

Creates an elliptic region of given bounding rectangle.

FoundationLite
CreateGridRegion CreateGridRegion

Creates a grid-shaped region with given parameters.

FoundationLite
CreateLineRegion CreateLineRegion

Creates a line region.

FoundationLite
CreatePathBorderRegion CreatePathBorderRegion

Creates a region along a given path. The region may be internal or external to the path.

FoundationLite
CreatePathRegion CreatePathRegion

Creates a region along the given path.

FoundationLite
CreatePolygonRegion CreatePolygonRegion

Creates a polygonal region corresponding to a given closed path.

FoundationLite
CreateRectangleBorderRegion CreateRectangleBorderRegion

Creates a frame-shaped region with given parameters.

FoundationLite
CreateRectangleRegion CreateRectangleRegion

Creates a region corresponding to a given rectangle.

FoundationLite
CreateRingRegion CreateRingRegion

Creates a ring-shaped region with given parameters.

FoundationLite
CreateSegmentRegion CreateSegmentRegion

Creates a segment region.

FoundationLite
EmptyRegion EmptyRegion

Creates an empty region with a given frame.

FoundationLite
GetRegionFrame GetRegionFrame

Returns the width and height of the entire region's frame (not to be confused with RegionBoundingBox!).

FoundationLite
LocationsToRegion LocationsToRegion

Forms a region containing pixels of given locations.

FoundationLite
RegionCharacteristicPoint RegionCharacteristicPoint

Returns a characteristic point of the input's region bounding box.

FoundationLite
RegionToLocations RegionToLocations

Converts a region to an array of its pixel locations.


It may be considered explicit region decompression.

FoundationLite
SetRegionFrame SetRegionFrame

Changes the width and the height of a region's frame (but does not rescale the content).

FoundationLite
SkipEmptyRegion SkipEmptyRegion

If the input region contains at least one pixel, then it is copied to the output; otherwise Nil is returned.


Secures against domain errors caused by empty regions, e.g. just before the RegionMassCenter filter is to be invoked.

FoundationLite
TestRegionEmpty TestRegionEmpty

Tests whether the size of a region equals zero.

FoundationLite
TestRegionNotEmpty TestRegionNotEmpty

Tests whether the size of a region doesn't equal zero.

FoundationLite
TestRegionOnBorder TestRegionOnBorder

Tests whether a region is adjacent to its border.

FoundationLite
VerifyRegion VerifyRegion

Checks if the point-runs of the input region are correctly arranged (sorted, not overlapping etc.).


You only need to use this tool if you create regions from point-runs manually.

FoundationLite

Region Combinators

Icon Name Description / Applications Modules
RegionDifference RegionDifference

Computes a region containing pixels from the first input region but not from the second input region.

FoundationLite
RegionIntersection RegionIntersection

Computes the common part of two regions.

FoundationLite
RegionIntersection_OfArray RegionIntersection_OfArray

Computes the common part of an array of regions.

FoundationLite
RegionIntersection_OfLoop RegionIntersection_OfLoop

Computes the common part of regions appearing in consecutive iterations.

FoundationLite
RegionSymmetricDifference RegionSymmetricDifference

Computes a region containing pixels from first or second input region, but not from both.

FoundationLite
RegionSymmetricDifference_OfArray RegionSymmetricDifference_OfArray

Computes a region containing pixels belonging to an odd number of array regions.

FoundationLite
RegionSymmetricDifference_OfLoop RegionSymmetricDifference_OfLoop

Computes a region containing pixels belonging to an odd number of regions appearing in consecutive iterations.

FoundationPro
RegionUnion RegionUnion

Computes a region containing pixels from both input regions.

FoundationLite
RegionUnion_OfArray RegionUnion_OfArray

Computes a region containing all the pixels that any of the input regions contains.

FoundationLite
RegionUnion_OfLoop RegionUnion_OfLoop

Computes the union of regions appearing in consecutive iterations.

FoundationLite

Region Features

Icon Name Description / Applications Modules
RegionArea RegionArea

Computes the number of pixels contained in a region.

FoundationLite
RegionBoundingBox RegionBoundingBox

Computes the smallest box containing a region.

FoundationLite
RegionBoundingBox_OrNil RegionBoundingBox_OrNil

Computes the smallest box containing a region; returns NIL if the region is empty.

FoundationLite
RegionBoundingCircle RegionBoundingCircle

Computes the smallest circle enclosing a region.

FoundationBasic
RegionBoundingCircle_OrNil RegionBoundingCircle_OrNil

Computes the smallest circle enclosing a region; returns NIL if the region is empty.

FoundationBasic
RegionBoundingEllipse RegionBoundingEllipse

Computes the smallest ellipse enclosing a region.

FoundationBasic
RegionBoundingEllipse_OrNil RegionBoundingEllipse_OrNil

Computes the smallest ellipse enclosing a region; returns NIL if the region is empty.

FoundationBasic
RegionBoundingParallelogram RegionBoundingParallelogram

Computes the smallest parallelogram containing a region.

FoundationPro
RegionBoundingRectangle RegionBoundingRectangle

Computes the smallest rectangle containing a region.

FoundationBasic
RegionBoundingRectangle_FixedAngle RegionBoundingRectangle_FixedAngle

Computes the smallest rectangle with the given orientation angle containing a region.

FoundationBasic
RegionBoundingRectangle_FixedAngle_OrNil RegionBoundingRectangle_FixedAngle_OrNil

Computes the smallest rectangle with the given orientation angle containing a region; returns NIL if the region is empty.

FoundationBasic
RegionBoundingRectangle_OrNil RegionBoundingRectangle_OrNil

Computes the smallest rectangle containing a region; returns NIL if the region is empty.

FoundationBasic
RegionCaliperDiameter RegionCaliperDiameter

Computes the longest and the shortest width of the input region measured as distance between parallel lines containing the whole region.

FoundationBasic
RegionCircularity RegionCircularity

Computes the area of a region divided by the area of a circular region having the same feature.

FoundationBasic
RegionComplexity RegionComplexity

Calculates how much the input region's perimeter is bigger than the perimeter of a circle of the same area.

FoundationBasic
RegionContours RegionContours

Computes an array of closed paths corresponding to the contours of the input region.

FoundationBasic
RegionConvexity RegionConvexity

Computes the area of a region divided by area of its convex hull.

FoundationBasic
RegionDiameter RegionDiameter

Computes the longest segment connecting two pixels contained in region and its length.

FoundationBasic
RegionDirectionalDispersion RegionDirectionalDispersion

Directional standard deviation of the distance of the region's points to the center.

FoundationBasic
RegionDispersion RegionDispersion

Calculates how much more the input region's points are dispersed comparing to the points of a circle of the same area.

FoundationBasic
RegionEllipticAxes RegionEllipticAxes

Computes axes of an ellipse having the same first and second order moments as the given region.

FoundationBasic
RegionElongation RegionElongation

Computes the elongation factor of a region ( perfect circle has minimal elongation equal 1.0 ).

FoundationBasic
RegionFeatureValue RegionFeatureValue

Computes the feature value of the input region.

FoundationBasic
RegionHoles RegionHoles

Creates regions of the holes of the input region.

FoundationBasic
RegionHoles_Elastic RegionHoles_Elastic

Fills a ridges region with convex basins.

FoundationBasic
RegionInscribedBox RegionInscribedBox

Computes the largest box contained in a region.

FoundationBasic
RegionInscribedCircle RegionInscribedCircle

Computes the largest circle contained in a region.

FoundationBasic
RegionMassCenter RegionMassCenter

Computes a point with coordinates equal to the average coordinates of the region's pixels.

FoundationLite
RegionMassCenter_OrNil RegionMassCenter_OrNil

Computes a point with coordinates equal to the average coordinates of the region's pixels; returns NIL if the region is empty.

FoundationLite
RegionMedialAxis RegionMedialAxis

Computes an array of paths corresponding to the skeleton of the input region.

FoundationBasic
RegionMoment RegionMoment

Computes selected second-order moment of a region in regular and normalized ( divided by region area ) variant.

FoundationBasic
RegionNumberOfHoles RegionNumberOfHoles

Computes the number of holes in a region.

FoundationBasic
RegionOrientation RegionOrientation

Computes the orientation of a region as an angle of value in a proper range.

FoundationBasic
RegionPerimeterLength RegionPerimeterLength

Computes the length of the input region perimeter.

FoundationBasic
RegionPointRunLengths RegionPointRunLengths

Returns the lengths of horizontal sequences of locations that constitute the input region.

FoundationBasic
RegionProjection RegionProjection

Computes the profile of the region pixel count in consecutive rows or columns.

FoundationBasic
RegionRectangularity RegionRectangularity

Computes the area of a region divided by the area of its bounding rectangle.

FoundationBasic
RegionsFeatureValues RegionsFeatureValues

Computes the feature values of the input regions.

FoundationBasic
RegionSkewness RegionSkewness

Directional standard deviation of the distance of the region's points to the center.

FoundationBasic
RegionThickness RegionThickness

Diameter of the biggest inscribed circle.

FoundationBasic

Region Global Transforms

Icon Name Description / Applications Modules
FillRegionHoles FillRegionHoles

Adds pixels to the input region so that it contains no holes.

FoundationBasic
RegionBoundaries RegionBoundaries

Removes interior pixels from a region.

FoundationBasic
RegionConvexHull RegionConvexHull

Computes the smallest convex region containing the input region.

FoundationBasic
RegionConvexHull_AsPath RegionConvexHull_AsPath

Computes the smallest convex polygon containing the input region.

FoundationBasic
RegionInteriors RegionInteriors

Removes boundary pixels from a region.

FoundationBasic
RegionOuterBoundaries RegionOuterBoundaries

Returns the top, right, bottom and left boundaries of the input region.

FoundationBasic
RemoveBordersFromRegion RemoveBordersFromRegion

Removes from a region the pixels that lie very close to the region's frame.


Assures that the resulting region is not "touching" the borders.

FoundationBasic
RemoveRegionBlobs RemoveRegionBlobs

Splits a region into blobs, removes blobs not fulfilling the specified condition, and merges the rest back into one region.

FoundationBasic
RemoveRegionBoundaryBlobs RemoveRegionBoundaryBlobs

Removes all blobs intersecting a boundary of a given region.

FoundationBasic
SplitRegionIntoBlobs SplitRegionIntoBlobs

Splits a region into an array of regions corresponding to its connected components.


Segmentation of a region into individual objects when the objects do not touch each other.

FoundationBasic
SplitRegionIntoComponents SplitRegionIntoComponents

Splits a region into an array of regions. Operates by merging blobs in accordance to the inMaxDistance parameter.

FoundationBasic
SplitRegionIntoExactlyNComponents SplitRegionIntoExactlyNComponents

Splits a region into a fixed-size array of regions.

FoundationBasic

Region IO

Icon Name Description / Applications Modules
LoadRegion LoadRegion

Loads a region from an FIDATA file.

FoundationLite
SaveRegion SaveRegion

Saves a serialized region object to an FIDATA file.

FoundationLite

Region Metrics

Icon Name Description / Applications Modules
RegionToRegionDistance RegionToRegionDistance

Computes minimal distance between one of the points of the first region with one of the points of the second region.

FoundationBasic

Region Morphology

Icon Name Description / Applications Modules
BottomHatRegion BottomHatRegion

Performs a morphological black top hat (bottom hat) operation on a region using a predefined kernel.

FoundationBasic
BottomHatRegion_AnyKernel BottomHatRegion_AnyKernel

Performs a morphological black top hat (bottom hat) operation on a region using an arbitrary kernel.

FoundationBasic
CloseRegion CloseRegion

Performs a morphological closing on a region using selected predefined kernel.


Filling-in small gaps in a region without making it thicker.

FoundationBasic
CloseRegion_AnyKernel CloseRegion_AnyKernel

Performs a morphological closing on a region using an arbitrary kernel.


Filling-in gaps of a particular shape without making the region thicker.

FoundationBasic
DemarcateRegions DemarcateRegions

Splits common pixels of the input regions among these regions.


Use this filter to make sure that the regions of an array do not intersect.

FoundationBasic
DilateRegion DilateRegion

Performs a morphological dilation on a region using a predefined kernel.


Making the region thicker or filling-in small holes within it.

FoundationBasic
DilateRegion_AnyKernel DilateRegion_AnyKernel

Performs a morphological dilation on a region using an arbitrary kernel.


Making the region thicker in a non-symmetrical way or filling-in gaps of a particular shape.

FoundationBasic
ErodeRegion ErodeRegion

Performs a morphological erosion on a region using a predefined kernel.


Making the region thinner or removing small parts.

FoundationBasic
ErodeRegion_AnyKernel ErodeRegion_AnyKernel

Performs a morphological erosion on a region using an arbitrary kernel.


Making the region thinner in a non-symmetrical way or removing small parts of a particular shape.

FoundationBasic
ErodeRegion_Threshold ErodeRegion_Threshold

Erodes a region with inThresholdValue pixels of inKernel.

FoundationBasic
ExpandRegions ExpandRegions

Splits pixels of the input regions and their complement among these regions.


Use this filter to make sure that every pixel belongs to a region.

FoundationBasic
OpenRegion OpenRegion

Performs a morphological opening on a region using a predefined kernel.


Removing small parts from a region without making it thinner.

FoundationBasic
OpenRegion_AnyKernel OpenRegion_AnyKernel

Performs a morphological opening on a region using an arbitrary kernel.


Removing small parts of a particular shape without making the region thinner.

FoundationBasic
PruneRegion PruneRegion

Removes one pixel wide branches from a region.

FoundationBasic
RegionHitAndMissTransform RegionHitAndMissTransform

Performs a hit-and-miss transformation on a region using arbitrary kernels.

FoundationBasic
SkeletonizeRegion SkeletonizeRegion

Thins a region to its skeleton.

FoundationBasic
ThickenRegion ThickenRegion

Performs a morphological thickening on a region using predefined kernels.

FoundationBasic
ThinRegion ThinRegion

Performs a morphological thinning on a region using predefined kernels.

FoundationBasic
ThresholdSmoothedRegion_Mean ThresholdSmoothedRegion_Mean

Returns region of pixels witch collect minAmount of pixels in rectangle in input region.

FoundationBasic
TopHatRegion TopHatRegion

Performs a morphological white top hat operation on a region using a predefined kernel.

FoundationBasic
TopHatRegion_AnyKernel TopHatRegion_AnyKernel

Performs a morphological white top hat operation on a region using an arbitrary kernel.

FoundationBasic

Region Point Transforms

Icon Name Description / Applications Modules
RegionComplement RegionComplement

Computes a region of pixels not contained in the input region.

FoundationLite

Region Relations

Icon Name Description / Applications Modules
ClassifyRegions ClassifyRegions

Splits an array of regions according to the selected feature and range.


Use this filter when you have an array of regions and you want to select some of them for further processing.

FoundationBasic
GetMaximumRegion GetMaximumRegion

Returns the region from the input array that corresponds to the largest computed feature value.


Use this filter when you have an array of regions and you want to select one of them that best matches some criterion.

FoundationBasic
GetMaximumRegion_OrNil GetMaximumRegion_OrNil

Returns the region from the input array that corresponds to the largest computed feature value; returns NIL if the array or any region inside it is empty.


Use this filter when you have an array of regions and you want to select one of them that best matches some criterion.

FoundationBasic
GetMinimumRegion GetMinimumRegion

Returns the region from the input array that corresponds to the smallest computed feature value.


Use this filter when you have an array of regions and you want to select one of them that best matches some criterion.

FoundationBasic
GetMinimumRegion_OrNil GetMinimumRegion_OrNil

Returns the region from the input array that corresponds to the smallest computed feature value; returns NIL if the array or any region inside it is empty.


Use this filter when you have an array of regions and you want to select one of them that best matches some criterion.

FoundationBasic
GroupPathsByRegions GroupPathsByRegions

For each region returns which paths lie inside of it or intersect with it.

FoundationBasic
GroupPointsByRegions GroupPointsByRegions

For each region returns which points lie inside of it.

FoundationBasic
GroupRegionsByRegions GroupRegionsByRegions

For each region returns which regions lie inside of it or intersect with it.

FoundationBasic
InscribeRegionInRegion InscribeRegionInRegion

Shifts source region so that it is contained in target region.

FoundationBasic
MakeRegionConditional MakeRegionConditional

Computes a region feature, checks whether its value is in range and creates a conditional region on this basis.

FoundationBasic
SelectRegions SelectRegions

Selects regions according to the selected feature and range.


Use this filter when you have an array of regions and you want to select some of them for further processing. It is slightly faster than ClassifyRegions.

FoundationBasic
SortRegions SortRegions

Changes the order of regions from the input array according to an ascending/descending sequence of their computed feature values.

FoundationBasic
TestPointArrayInRegion TestPointArrayInRegion

Tests which points lie inside a region.

FoundationBasic
TestPointInRegion TestPointInRegion

Tests whether a point lies inside a region.

FoundationLite
TestRegionEqualTo TestRegionEqualTo

Tests whether given regions are equal.

FoundationBasic
TestRegionInRegion TestRegionInRegion

Tests whether a region is contained in another one.

FoundationBasic
TestRegionIntersectsWith TestRegionIntersectsWith

Tests whether two regions have non-empty intersection.

FoundationBasic
TestRegionUnequalTo TestRegionUnequalTo

Tests whether given regions are not equal.

FoundationBasic

Region Spatial Transforms

Icon Name Description / Applications Modules
AlignRegion AlignRegion

Aligns a region to a coordinate system.


Most typically used, when there is a region extracted after performing CropImageToRectangle. This filter makes it possible to align the region with the original image.

FoundationBasic
CropRegion CropRegion

Creates a region from a rectangular fragment of another one.


Can be used to obtain a part of a bigger region, but also to enforce specific region frame.

FoundationLite
CropRegionToQuadrangle CropRegionToQuadrangle

Creates a region from a quadrangular fragment of another one. The quadrangle must be convex.

FoundationPro
CropRegionToRectangle CropRegionToRectangle

Creates a region from a rectangular fragment of another one.


Can be used to obtain a part of a bigger region, but also to enforce specific region frame.

FoundationLite
DownsampleRegion DownsampleRegion

Shrinks a region by the factor of two along each axis.

FoundationBasic
EnlargeRegionNTimes EnlargeRegionNTimes

Enlarges a region by a natural factor.

FoundationBasic
MirrorRegion MirrorRegion

Mirrors a region across vertical or horizontal axis.

FoundationBasic
ReflectRegion ReflectRegion

Reflects a region through the given location.

FoundationBasic
ResizeRegion ResizeRegion

Enlarges or shrinks a region to new dimensions.

FoundationBasic
ResizeRegion_Relative ResizeRegion_Relative

Resizes region relatively along each axis.

FoundationBasic
RotateRegion RotateRegion

Rotates a region around a specified point.

FoundationBasic
ShearRegion ShearRegion

Computes a leant region.

FoundationBasic
ShrinkRegionNTimes ShrinkRegionNTimes

Shrinks a region by a natural factor along each axis.

FoundationBasic
TranslateRegion TranslateRegion

Translates a region by a given number of pixels along each axis.

FoundationLite
TransposeRegion TransposeRegion

Flips and rotates a region so that x-coordinates are exchanged with y-coordinates.

FoundationBasic
TrimRegionToPolygon TrimRegionToPolygon

Removes region elements lying beyond the specified polygon.

FoundationPro
TrimRegionToRectangle TrimRegionToRectangle

Limits a region to a rectangular area.

FoundationPro
UncropRegion UncropRegion

Inverse of CropRegion.

FoundationLite