ImageGrayscale()

Converts an image to grayscale.

Requires Extension: Image extension

ImageGrayscale( image=any );

Returns: void

Argument Description
image
any, required

The image on which this operation is performed.

Alias: name

Examples

img=imageRead("https://hostek.com/blog/wp-content/uploads/2015/11/magician_lucee_wide.jpg");
imageGrayScale(img);
imageresize(img, "20%","200");
cfimage(action="writeToBrowser",source=img);

See also