You are here: Start » AVL.NET » Function Reference » Region » Region Morphology » AVL.SkeletonizeRegion

AVL.SkeletonizeRegion

Thins a region to its skeleton.

Namespace:AvlNet
Assembly:AVL.NET.dll

Syntax

C++
C#
 
public static void SkeletonizeRegion
(
	AvlNet.Region inRegion,
	AvlNet.RegionSkeletonMethod inRegionSkeletonMethod,
	AvlNet.Region outRegion
)

Parameters

Name Type Range Default Description
inRegionAvlNet.RegionInput region.
inRegionSkeletonMethodAvlNet.RegionSkeletonMethodTwelveConnectedDefault value: TwelveConnected.
outRegionAvlNet.RegionOutput region.

Description

The operation performs skeletonization presenting result as a region.

Skeleton of a region is a connected set of medial axis of its limbs. It is a useful tool when one is interested only in general structure of a shape and wants to disregard width of its limbs. Two methods are available, depending on the value of inRegionSkeletonMethod being chosen:

  • EightConnected: the input region is thinned as long as the thinning procedure affects it; the structuring elements come from the well known Golay alphabet
  • TwelveConnected: the input region is thinned also, but the structuring elements being used are slightly larger than in previous method (they consider 12-neighborhood of the given pixel instead of 8-neighborhood). The method comes from the paper of U. Eckhardt and G. Maderlechner "Invariant thinning"

The second method is slower than the first one, but its results look in most cases much better than the first one's results.

This filter is a cousin of RegionMedialAxis which represents the results as an array of paths instead of a region.

Examples

SkeletonizeRegion run on a sample region with inRegionSkeletonMethod = TwelveConnected.

See also