Aging method (Main Control)

C++ Builder example

Delphi example

 

Builder Syntax

int Aging(unsigned uHScratchCount, unsigned uVScratchCount, unsigned uMaxScratchLen, unsigned uDustDensity, unsigned uPitsDensity, unsigned uMaxPitSize, unsigned crScratch, unsigned crDust, unsigned crPits, unsigned uFlags);

Delphi Syntax

Function Aging (uHScratchCount: L_UINT; uVScratchCount: L_UINT; uMaxScratchLen: L_UINT; uDustDensity: L_UINT; uPitsDensity: L_UINT; uMaxPitSize: L_UINT; crScratch: COLORREF; crDust: COLORREF; crPits: COLORREF; uFlags: L_UINT): L_INT;

Overview

Refer to Applying Artistic Effects

Remarks

(Raster Pro and above toolkits.) Adds effects that simulate random color changes, scratches, dust and pits, making the bitmap currently loaded in the Main Control look like it was made from an old film. The bitmap loaded in the Main Control can be accessed through the Bitmap property(Main Control).

The width of the scratches is 1 pixel. The length of the scratches is random (between 2 and uMaxScratchLen). The size of dust particles is 1 pixel (1x1). The size and shape of pits is selected at random. The pit shapes are random and will be between 1x1 and uMaxPitSize x uMaxPitSize.

The method will also make random changes to the pixel’s intensities.

This method supports 12 and 16-bit grayscale and 48 and 64-bit color images. Support for 12 and 16-bit grayscale and 48 and 64-bit color images is available only in the Document/Medical toolkits.

This method does not support signed data images. It returns the error code ERROR_SIGNED_DATA_NOT_SUPPORTED if a signed data image is passed to this method.

See Also

Elements:

Sharpen method, Posterize method, Emboss method, AddNoise method, IntensityDetect method, SpatialFilter method, BinaryFilter method, MaxFilter method, MinFilter method, Oilify method, Solarize method, WindowLevel method, Mosaic method.

Topics:

Raster Images: Modifying Intensity Values

 

Raster Images: Artistic Effects

 

Using Color Values in LEADTOOLS