PHP | Gmagick equalizeimage() Function Last Updated : 24 Mar, 2021 Comments Improve Suggest changes Like Article Like Report The Gmagick::equalizeimage() function is an inbuilt function in PHP which is used to equalizes the histogram of an image.Syntax: Gmagick Gmagick::equalizeimage( void ) Parameters: This function does not accepts any parameter. Return Value: This function returns equalized Gmagick object. Errors/Exceptions: This function throws GmagickException on error. Below programs illustrate the Gmagick::equalizeimage() function in PHP: Program 1: Original Image: PHP <?php // Create a Gmagick object $gmagick = new Gmagick( 'https://media.geeksforgeeks.org/wp-content/uploads/tech.png'); // Equalize the image. $gmagick->equalizeimage(); header('Content-type: image/png'); // Output the image echo $gmagick; ?> Output: Program 2: PHP <?php // Create a GmagickDraw object $draw = new GmagickDraw(); // Create GmagickPixel object $strokeColor = new GmagickPixel('Red'); $fillColor = new GmagickPixel('Green'); // Set the color, opacity of image $draw->setStrokeOpacity(1); $draw->setStrokeColor('Red'); $draw->setFillColor('Green'); // Set the width and height of image $draw->setStrokeWidth(7); $draw->setFontSize(72); // Function to draw circle $draw->circle(250, 250, 100, 150); $gmagick = new Gmagick(); $gmagick->newImage(500, 500, 'White'); $gmagick->setImageFormat("png"); $gmagick->drawImage($draw); // Equalize the image $gmagick->equalizeimage(); // Display the output image header("Content-Type: image/png"); echo $gmagick->getImageBlob(); ?> Output: Reference: http://php.net/manual/en/gmagick.equalizeimage.php Comment More infoAdvertise with us Next Article PHP | Gmagick equalizeimage() Function S sarthak_ishu11 Follow Improve Article Tags : Web Technologies PHP Image-Processing PHP-function PHP-Gmagick +1 More Similar Reads PHP | Imagick equalizeImage() Function The Imagick::equalizeImage() function is an inbuilt function in PHP which is used to equalizes the histogram of an image. Syntax: bool Imagick::equalizeImage( void ) Parameter: This function does not accepts any parameter. Return Value: This function returns True on success. Original Image: Below pr 1 min read PHP | Gmagick edgeimage() Function The Gmagick::edgeimage() function is an inbuilt function in PHP which is used to enhance the image edges using convolution filter of the given radius. Radius 0 is used as auto-selected.Syntax:Â Â Gmagick Gmagick::edgeimage( $radius ) Parameters: This function accepts a single parameter as $radius whi 1 min read PHP | Gmagick enhanceimage() Function The Gmagick::enhanceimage() function is an inbuilt function in PHP which is used to improve the quality of a noisy image. This function applies the digital filter to improve quality.Syntax:Â Â Gmagick Gmagick::enhanceimage( void ) Parameters: This function does not accepts any parameter.Return Value: 1 min read PHP | Gmagick addImage() Function The Gmagick::addImage() function is an inbuilt function in PHP which is used to adds new image to Gmagick object image list. This function adds a new image to Gmagick object from the current position of the source object. The Gmagick class have the ability to hold and operate on multiple images simu 2 min read PHP | Gmagick addnoiseimage() Function The Gmagick::addnoiseimage() function is an inbuilt function in PHP which is used to add noise in given image. The intensity of noise depends on noise constants and channel types. The image noise is the random variation of brightness and contrast in an image. Syntax:Â Gmagick Gmagick::addnoiseimage 2 min read Like