RegionNumberOfHoles
Computes the number of holes in a region.
Syntax
C++
C#
Python
def RegionNumberOfHoles( inRegion: Region, /, *, inConnectivity: RegionConnectivity = RegionConnectivity.EightDirections, inMinHoleArea: int = 1, inMaxHoleArea: int | None = None ) -> outNumberOfHoles: int
Parameters
| Name | Type | Range | Default | Description | |
|---|---|---|---|---|---|
![]() |
inRegion | Region | Input region | ||
![]() |
inConnectivity | RegionConnectivity | RegionConnectivity.EightDirections | Region connectivity semantics | |
![]() |
inMinHoleArea | int | 0 - ![]() |
1 | Minimal area of a hole |
![]() |
inMaxHoleArea | int | None | 0 - ![]() |
None | Maximal area of a hole |
![]() |
outNumberOfHoles | int |



