Open In App

PHP | Imagick shadeImage() Function

Last Updated : 26 Aug, 2019
Summarize
Comments
Improve
Suggest changes
Like Article
Like
Share
Report
News Follow

The Imagick::shadeImage() function is an inbuilt function in PHP which is used to creates a 3D effect of a given image. Shines a distant light on an image to create a three-dimensional effect. The azimuth is measured in degrees of x-axis and elevation is measured in pixels above the z-axis.

Syntax:

bool Imagick::shadeImage( $gray, $azimuth, $elevation )

Parameters: This function accepts three parameters as mentioned above and described below:

  • $gray: This parameter stores the value other than zero and shades the intensity of each pixel.
  • $azimuth: This parameter stores the value of the light source direction. It is measured in degrees of the x-axis.
  • $elevation: This parameter stores the value of the light source direction. It is measured in pixels above the z-axis.

Return Value: This function returns True on success.

Original Image:

Below program illustrates the Imagick::shadeImage() function in PHP:

Program:





Output:

Related Articles:

Reference: http://php.net/manual/en/imagick.shadeimage.php



Similar Reads

three90RightbarBannerImg