PHP | Gmagick getimagegamma() Function Last Updated : 21 Jan, 2020 Comments Improve Suggest changes Like Article Like Report The Gmagick::getimagegamma() function is an inbuilt function in PHP which is used to get the image gamma. The Gamma is a nonlinear operation used to encode and decode luminance or tristimulus values in images. Syntax: float Gmagick::getimagegamma( void ) Parameters: This function doesn’t accept any parameter. Return Value: This function returns an float value containing the gamma. Exceptions: This function throws GmagickException on error. Below given programs illustrate the Gmagick::getimagegamma() function in PHP: Program 1 (For image with multiple colors): php <?php // Create a new Gmagick object // https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png $gmagick = new Gmagick('geeksforgeeks.png'); // Get the gamma $gamma = $gmagick->getimagegamma(); echo $gamma; ?> Output: 0.45454999804497 Program 2 (For image with single color): php <?php // Create a new Gmagick object // https://media.geeksforgeeks.org/wp-content/uploads/20200106200505/singlecolor.png $gmagick = new Gmagick('singlecolor.png'); // Get the gamma $gamma = $gmagick->getimagegamma(); echo $gamma; ?> Output: 0 Reference: https://www.php.net/manual/en/gmagick.getimagegamma.php Comment More infoAdvertise with us Next Article PHP | Gmagick getimagegamma() Function gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Gmagick Similar Reads PHP | Imagick getImageGamma() Function The Imagick::getImageGamma() function is an inbuilt function in PHP which is used to get the Gamma value of the image. The Gamma is a nonlinear operation used to encode and decode luminance or tristimulus values in images. Syntax: float Imagick::getImageGamma( void ) Parameters: This function does n 1 min read PHP | Gmagick getImageMatte() Function The Gmagick::getImageMatte() function is an inbuilt function in PHP which is used to get the matte channel of an Gmagick object. Syntax: int Gmagick::getimagematte( void ) Parameters: This function does not accept any parameter. Return Value: This function returns True if image contains matte channe 1 min read PHP | Gmagick getimageformat() Function The Gmagick::getimageformat() function is an inbuilt function in PHP which returns the format of an image. Syntax: string Gmagick::getimageformat( void ) Parameters: This function does not accepts any parameter. Return Value: This function returns the image format in form of string on success. Below 1 min read PHP | Gmagick getimageextrema() Function The Gmagick::getimageextrema() function is an inbuilt function in PHP which is used to get the extrema for an image. Extrema are the points at which a maximum or minimum value of a function is observed. Syntax: array Gmagick::getimageextrema( void ) Parameters:This function doesnât accept any parame 1 min read PHP | Gmagick getimagehistogram() Function The Gmagick::getimagehistogram() function is an inbuilt function in PHP which is used to get the image histogram. This function returns all the pixels from the picture in the form of an array of Gmagick pixels. We can use this function to analyze the color of any picture pixel by pixel. Syntax: arra 2 min read PHP | Gmagick getimagedelay() Function The Gmagick::getimagedelay() function is an inbuilt function in PHP which is used to get the image delay. The delay is actually the time taken for the transition from one image to another in a gif animation. Syntax: int Gmagick::getimagedelay( void ) Parameters: This function doesnât accepts any par 1 min read PHP | Imagick getImageMatte() Function The Imagick::getImageMatte() function is an inbuilt function in PHP which is used to get the matte channel of an imagick object.Syntax:  bool Imagick::getImageMatte( void ) Parameters: This function does not accept any parameter.Return Value: This function returns True if image has a matte channel 1 min read PHP | Gmagick getimagefilename() Function The Gmagick::getimagefilename() function is an inbuilt function in PHP which is used to get the filename of a particular image in a sequence. Syntax: string Gmagick::getimagefilename( void ) Parameters: This function doesnât accept any parameter. Return Value: This function returns an string value c 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 PHP | Gmagick getimageheight() Function The Gmagick::getimageheight() function is an inbuilt function in PHP which is used to get the image height which is the vertical length of the image. Syntax: int Gmagick::getimageheight( void ) Parameters: This function doesnât accept any parameters. Return Value: This function returns an integer va 1 min read Like