#include "BIFILTER.H"
HANDLE CALLBACK ComputeLUT( HANDLE hHistogram,
int nMode,
HANDLE hLUT,
int nContrast,
int nBrightness,
LPINT lpnErrorFlag)
Description
Compute the scaled/shifted LUT on the base of histogram and user parameters, for recolouring the pixel values, using linear transfer function.
Scaling results in changing the contrast (gain), shifting results in changing the brightness (offset).
nMode set the way of working
OPEN Create the LUT.
COMPUTE Compute the actual LUT.
CLOSE Destroy the LUT
Parameters
|
HANDLE |
hHistogram |
Handle to a histogram.(256 unsigned byte). |
|
int |
nMode |
Create, destroy or compute LUT. |
|
HANDLE |
hLUT |
Handle to LUT.(256 unsigned byte). If this paramter is set to zero, a new LUT, otherwise this handle will be returned. |
|
int |
nContrast |
Value of the contrast. |
|
int |
nBrightness |
Value of the brightness. |
|
LPINT |
lpnErrorFlag |
Pointer to an error code. If IOK there is no error. |
Return values
Return a handle to a LUT if successful or NULL if fails.
Programming notes
None.
Requirements
Header : Declared in BIFilter.h; include BIFilter.h.
Library : Use BIFilter.lib.
DLLs : BIFilter.dll.
Code example
None at present.