Back to Aurora Vision Library website

You are here: Start » Function Reference » Image » Image Features » ImageHistogram

ImageHistogram


Header: AVL.h
Namespace: avl
Module: FoundationBasic

Computes the histogram of the image pixel values.

Syntax

C++
C#
 
void avl::ImageHistogram
(
	const avl::Image& inImage,
	atl::Optional<const avl::Region&> inRoi,
	int inChannelIndex,
	float inDomainBegin,
	const float inBinSize,
	int inBinCount,
	avl::Histogram& outHistogram
)

Parameters

Name Type Range Default Description
Input value inImage const Image& Input image
Input value inRoi Optional<const Region&> NIL Range of pixels to be processed
Input value inChannelIndex int 0 - 3 Selects a channel of the input image
Input value inDomainBegin float 0.0f The lowest value that will be considered in the output histogram
Input value inBinSize const float 0.0 - 1.0f Width of a single histogram bin
Input value inBinCount int 256 The upper-bound for values that will be considered in the output histogram
Output value outHistogram Histogram& Output histogram

Description

Histogram in Aurora Vision Studio is a graphical representation of data contained in image. That is, the resulting histogram contains number of pixel values from specified channel with selected inBinSize (interval).

Examples

ImageHistogram performed on the Lena image with inChannelIndex = 0, inBinSize = 1.

Errors

List of possible exceptions:

Error type Description
DomainError Region exceeds an input image in ImageHistogram.
DomainError Selected bin size equals zero in ImageHistogram.
DomainError Selected channel index is out of range in ImageHistogram.

See Also

  • MakeHistogram – Creates a histogram out of an array of bin values.