Back to FabImage Library website
You are here: Start » Function Reference » Histogram Basics » MakeHistogram

MakeHistogram
Header: | FIL.h |
---|---|
Namespace: | fil |
Creates a histogram assuming given bin values.
Syntax
C++
C#
void fil::MakeHistogram ( const ftl::Array<int>& inValues, float inDomainStart, float inDomainLength, float inBinSize, fil::Histogram& outHistogram )
Parameters
Name | Type | Range | Default | Description | |
---|---|---|---|---|---|
![]() |
inValues | const Array<int>& | Input array of bin values | ||
![]() |
inDomainStart | float | 0.0f | Input domain begin | |
![]() |
inDomainLength | float | 0.0 - ![]() |
256.0f | Input domain length |
![]() |
inBinSize | float | 0.0 - ![]() |
1.0f | Input length of the domain range covered by a single bin |
![]() |
outHistogram | Histogram& | Output histogram |
Remarks
The calculated bin count must be equal to element count of the inValues array.
Errors
List of possible exceptions:
Error type | Description |
---|---|
DomainError | Empty inValues array on input in MakeHistogram. |
DomainError | Non-positive value of inBinSize in MakeHistogram. |
DomainError | The calculated bin count is greater than input values count in MakeHistogram. |
DomainError | The calculated bin count is less than input values count in MakeHistogram. |