ImgHistoDelete

Top  Previous  Next

Prototype

 

ImgHistoDelete(intHistoHandle)

 

Description

 

Delete an histogram handle.

 

Parameters

 

intHistoHandle: integer value corresponding to the histogram handle obtained using ImgHistoCreate.

 

Returned value

 

None.

 

Notes

 

Each ImgHistoCreate function should be balanced with an ImgHistoDelete function to avoid memory leacks.

 

Example

 

// Show the number of pixels for each gray level

HistoHandle:=ImgHistoCreate(_CurrentImage);

 

for Level:=0 to 255 do

begin

 PixelCount:=ImgHistoValue(HistoHandle,Level);

 ApplicationLog('The graylevel ' + IntToStr(Level) + ' counts '+ IntToStr(PixelCount)+ ' pixels.');

end;

 

ImgHistoDelete(HistoHandle);