PHP | Imagick setImageGamma() Function Last Updated : 19 Nov, 2019 Comments Improve Suggest changes Like Article Like Report The Imagick::setImageGamma() function is an inbuilt function in PHP which is used to set the image gamma. Syntax: bool Imagick::setImageGamma( float $gamma ) Parameters: This function accepts a single parameter $gamma which holds the gamma for the image. Return Value: This function returns TRUE on success. Exceptions: This function throws ImagickException on error. Below given programs illustrate the Imagick::setImageGamma() function in PHP: Program 1: php <?php // Create a new imagick object $imagick = new Imagick( 'https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png'); // Set the Gamma $imagick->setImageGamma(5); // Display the image header("Content-Type: image/png"); echo $imagick->getImageBlob(); ?> Output: Program 2: php <?php // Create a new imagick object $imagick = new Imagick( 'https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png'); // Set the Gamma $imagick->setImageGamma(15); // Add a border $imagick->borderImage('black', 2, 2); // Display the image header("Content-Type: image/png"); echo $imagick->getImageBlob(); ?> Output: Reference: https://www.php.net/manual/en/imagick.setimagegamma.php Comment More infoAdvertise with us Next Article PHP | Imagick setImageGamma() Function G gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Imagick Similar Reads PHP | Imagick setImagePage() Function The Imagick::setImagePage() function is an inbuilt function in PHP which is used to set the image page geometry. Syntax: bool Imagick::setImagePage(int $width, int $height, int $x, int $y ) Parameters: This function accepts four parameters as mentioned above and described below: $width: It specifies 1 min read PHP | Imagick setImageFormat() Function The Imagick::setImageFormat() function is an inbuilt function in PHP which is used to set the format of a particular image in a sequence.Syntax:Â Â bool Imagick::setImageFormat( string $format ) Parameters: This function accepts a single parameter $format which holds a string value of the image forma 1 min read PHP | Imagick setImageGravity() Function The Imagick::setImageGravity() function is an inbuilt function in PHP which is used to set the gravity property of an image. Difference between setGravity() and setImageGravity() is that the former applies for the whole Imagick object whereas the latter sets the gravity of the current image (in case 1 min read PHP | Imagick setImageFilename() Function The Imagick::setImageFilename() function is an inbuilt function in PHP which is used to set the filename of a particular image. Syntax: bool Imagick::setImageFilename( string $filename ) Parameters: This function accepts single parameter $filename which holds a string that represent the filename. Re 1 min read PHP | Imagick setImageArtifact() Function The Imagick::setImageArtifact() function is an inbuilt function in PHP which is used to set the image artifact. The main difference between image properties and image artifacts is that the properties are public whereas artifacts are private. Syntax: bool Imagick::setImageArtifact( string $artifact, 1 min read Like