Back to Adaptive Vision Library website

You are here: Start » Function Reference » Region » Region Global Transforms » FillRegionHoles

FillRegionHoles


Header: AVL.h
Namespace: avl
Module: FoundationBasic

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

Syntax

C++
C#
 
void avl::FillRegionHoles
(
	const avl::Region& inRegion,
	avl::RegionConnectivity::Type inConnectivity,
	int inMinHoleArea,
	atl::Optional<int> inMaxHoleArea,
	avl::Region& outRegion
)

Parameters

Name Type Range Default Description
inRegion const Region& Input region
inConnectivity RegionConnectivity::Type Type of connectivity used for the region foreground
inMinHoleArea int 0 - Minimal area of a hole to be filled
inMaxHoleArea Optional<int> 0 - NIL Maximal area of a hole to be filled
outRegion Region& Output region

Description

The operation extends a region to contain all pixels inside any of the region holes. Holes of a region are those connected areas of pixels not belonging to the region, that do not touch the boundary of the region frame.

Examples

FillRegionHoles run on a sample region.

Remarks

This filter is mostly used in Blob Analysis Technique please refer to our Machine Vision Guide - Blob Analysis article.

See Also