PHP | Gmagick getimagecompose() Function Last Updated : 21 Jan, 2020 Comments Improve Suggest changes Like Article Like Report The Gmagick::getimagecompose() function is an inbuilt function in PHP which is used to get the composite operator associated with the image. The composite operator decides the method to be used for image composition. The composite operator can be anyone from given COMPOSITE OPERATOR constants. Syntax: int Gmagick::getimagecompose( void ) Parameters:This function doesn’t accept any parameter. Return Value: This function returns an integer value containing the compose operator. Exceptions: This function throws GmagickException on error. Below given programs illustrate the Gmagick::getimagecompose() function in PHP: Program 1: php <?php // Create a new Gmagick object // https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png $gmagick = new Gmagick('geeksforgeeks.png'); // Get the image compose $compose = $gmagick->getimagecompose(); echo $compose; ?> Output: 1 // Which is the default composite operator for all Gmagick object. Program 2: php <?php // Create a new Gmagick object // https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png $gmagick = new Gmagick('geeksforgeeks.png'); // Set the image compose $gmagick->setimagecompose(Gmagick::COMPOSITE_COLORIZE); // Get the image compose $compose = $gmagick->getimagecompose(); echo $compose; ?> Output: 28 Reference: https://www.php.net/manual/en/gmagick.getimagecompose.php Comment More infoAdvertise with us Next Article PHP | Gmagick getimagecompose() Function G gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Gmagick Similar Reads PHP | Imagick getImageCompose() Function The Imagick::getImageCompose() function is an inbuilt function in PHP which is used to get the composite operator associated with the image. Syntax: int Imagick::getImageCompose( void ) Parameters: This function does not accept any parameter. Return Value: This function returns TRUE on success. Belo 1 min read PHP | Gmagick getimagecolors() Function The Gmagick::getimagecolors() function is an inbuilt function in PHP which is used to get the number of unique colors in the image. Syntax: int Gmagick::getimagecolors( void ) Parameters:This function doesnât accept any parameter. Return Value: This function returns an integer value. Exceptions: Thi 2 min read PHP | Gmagick getImageDispose() Function The Gmagick::getImageDispose() function is an inbuilt function in PHP which is used to return the image disposal method. Syntax: int Gmagick::getImageDispose( void ) Parameters: This function does not accept any parameter. Return Value: This function returns the dispose method on success. Below prog 1 min read PHP | Gmagick getimagecolorspace() Function The Gmagick::getimagecolorspace() function is an inbuilt function in PHP which is used to get the image colorspace. The color space is a mathematical model which describes the range of colors as tuples of numbers, typically as 3 or 4 values are color components(RGB). Syntax: int Gmagick::getimagecol 1 min read PHP | Gmagick getimagetype() Function The Gmagick::getimagetype() function is an inbuilt function in PHP which is used to get the image type. Syntax: int Gmagick::getimagetype( void ) Parameters: This function doesnât accept any parameters. Return Value: This function returns an integer value corresponding to one of the IMGTYPE constant 1 min read Like