PHP | Gmagick setimageprofile() Function Last Updated : 23 Jan, 2020 Comments Improve Suggest changes Like Article Like Report The Gmagick::setimageprofile() function is an inbuilt function in PHP which is used to add a named profile to the Gmagick object. Syntax: Gmagick Gmagick::setimageprofile( string $name, string $profile ) Parameters: This function accepts two parameters as mentioned above and described below: $name: It specifies the name of the profile. $profile: It specifies the value of the profile. Return Value: This function returns Gmagick object on success. Exceptions: This function throws GmagickException on error. Below given programs illustrate the Gmagick::setimageprofile() function in PHP: Used Image: Program 1: php <?php // Create a new Gmagick object $gmagick = new Gmagick('geeksforgeeks.png'); // Set the image profile $gmagick->setimageprofile('profile_name', 'profile_value'); // Get the image profile $profile = $gmagick->getimageprofile("profile_name"); echo $profile; ?> Output: profile_value Program 2: php <?php // Create a new Gmagick object $gmagick = new Gmagick('geeksforgeeks.png'); // Set the color using image profile $gmagick->setImageProfile('color', 'blue'); // Use the image profile $gmagick->borderimage($gmagick->getimageprofile('color'), 5, 5); // Display the image header("Content-Type: image/png"); echo $gmagick->getImageBlob(); ?> Output: Reference: https://www.php.net/manual/en/gmagick.setimageprofile.php Comment More infoAdvertise with us Next Article PHP | Gmagick setimageprofile() Function G gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Gmagick Similar Reads PHP | Imagick setImageProfile() Function The Imagick::setImageProfile() function is an inbuilt function in PHP which is used to set the named profile to the Imagick object. Syntax: bool Imagick::setImageProfile( string $name, string $profile ) Parameters:This function accepts two parameters as mentioned above and described below: $name: It 1 min read PHP | Gmagick setimagefilename() Function The Gmagick::setimagefilename() function is an inbuilt function in PHP which is used to set the filename of a particular image in a sequence. Syntax: Gmagick Gmagick::setimagefilename( string $filename ) Parameters: This function accepts a single parameter $filename which holds the name of the file. 1 min read PHP | Gmagick setimagetype() Function The Gmagick::setimagetype() function is an inbuilt function in PHP which is used to set the image type. Syntax: Gmagick Gmagick::setimagetype( int $imgType ) Parameters: This function accepts a single parameter $imgType which holds an integer value corresponding to one of the IMGTYPE constants. All 2 min read PHP | Gmagick setImageDispose() Function The Gmagick::setImageDispose() function is an inbuilt function in PHP which is used to sets the image disposal method. Syntax: Gmagick Gmagick::setimagedispose( $disposeType ) Parameters: This function accepts a single parameter $disposeType which specifies the image disposal type. Return Value: Thi 2 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 Like