PHP | Imagick vignetteImage() Function
The Imagick::vignetteImage() function is an inbuilt function in PHP which is used to add vintage filter to the image. This function illustrate or portrait an image which fades into its background without a definite border.
Syntax:
bool Imagick::vignetteImage( $blackPoint, $whitePoint, $x, $y )
Parameters: This function accepts four parameters as mentioned above and described below:
- $blackPoint: This parameter is used to store the value of black point.
- $whitePoint: This parameter is used to store the value of white point.
- $x: This parameter stores the value of the X offset of the ellipse.
- $y: This parameter stores the value of the Y offset of the ellipse.
Return Value: This function returns True on success.
Original Image:

Below program illustrates the Imagick::vignetteImage() function in PHP:
Program:
<?php // require_once('path/vendor/autoload.php'); // Create an Imagick Object $imagick = new Imagick( // vignetteImage Function $imagick->vignetteImage(35.6, 11.8, 40, 15); // Image Header header("Content-Type: image/jpg"); // Display image echo $imagick->getImageBlob(); ?> |
Output:

Related Articles:
Reference: http://php.net/manual/en/imagick.vignetteimage.php
Recommended Posts:
- PHP | Imagick getImagePage() Function
- PHP | Imagick setImageDepth() Function
- PHP | Imagick getImageFormat() Function
- PHP | Imagick recolorImage() Function
- PHP | Imagick getImageUnits() Function
- PHP | Imagick setImageUnits() Function
- PHP | Imagick raiseImage() Function
- PHP | Imagick getImageGeometry() Function
- PHP | Imagick setImageResolution() Function
- PHP | Imagick getImageLength() Function
- PHP | Imagick identifyImage() Function
- PHP | Imagick rollImage() Function
- PHP | Imagick getImageDepth() Function
- PHP | Imagick displayImage() Function
- PHP | Imagick reduceNoiseImage() Function
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.




