You are here: Start » AVL.NET » AVL.SegmentImage_Gray(AvlNet.Image, AvlNet.Region, float, AvlNet.BlobsDifferenceMeasure, int, int?, AvlNet.Region[])

AVL.SegmentImage_Gray(AvlNet.Image, AvlNet.Region, float, AvlNet.BlobsDifferenceMeasure, int, int?, AvlNet.Region[])

Segments an image into blobs examining differences between neighbouring pixels values.

Namespace:AvlNet
Assembly:AVL.NET.dll

Syntax


public static void SegmentImage_Gray(
	AvlNet.Image inImage,
	AvlNet.Region inRoi,
	float inMaxDifference,
	AvlNet.BlobsDifferenceMeasure inDifferenceMeasure,
	int inMinArea,
	int? inMaxArea,
	out AvlNet.Region[] outBlobs
)

Parameters

inImage
Type: AvlNet.Image
Image from which blobs are extracted
inRoi
Type: AvlNet.Region
Range of pixels to be processed, or null.
inMaxDifference
Type: System.Single
Maximal difference between two neighbouring blobs to be merged
inDifferenceMeasure
Type: AvlNet.BlobsDifferenceMeasure
Measure of blobs difference
inMinArea
Type: System.Int32
Minimal area of a blob
inMaxArea
Type: System.Nullable<System.Int32>
Maximal area of a blob, or null.
outBlobs
Type: AvlNet.Region
Blobs extracted from the input image

Description

The filter segments the inImage image into blobs of adjacent pixels which gray values do not differ too much. The classification is different depending on the inDifferenceMeasure method:

  • if Mean is selected, pixel is considered to belong to an adjacent blob when its value differs by at most inMaxDifference from the mean value of this blob's pixels
  • if Neighbour is selected, two adjacent pixels are considered to belong to the same blob when their values differ by at most inMaxDifference

Examples

SegmentImage_Gray performed on the sample image with inMaxDifference = 55, inDifferenceMeasure = Mean and inMinArea = 50.

Errors

Error type Description
DomainError Not supported difference measure in SegmentImage_Gray.

See also