phMagick :: Rounded Corners
There is’nt mutch to say about this, just call the function
$phMagick = &new phMagick('resize_porp_wh.png'); $phMagick->setDestination('rounded.png') ->roundCorners();// default is 15px $phMagick = &new phMagick('resize_porp_wh.png'); $phMagick->setDestination('rounded1.png') ->roundCorners(35);
| Original Image | Rounded 15px | rounded 35px |
![]() |
![]() |
![]() |



Hello, I liked your ext PhMagick.
I would like to apply it to work.
But do not succeed effects corners and others.
How do I install Imagemagick, so that all modules work?
Hello Mirkus,
You can try to run phMagick in debug mode and see if any errors are reported (see http://www.francodacosta.com/blog/phmagick/examples/debugging-phmagick )
For rounded corners you will need an image in a format that supports transparency (alpha channel) such as PNG
To install ImageMagick just go to http://www.imagemagick.org and download the appropriate package for you system, to handle PDF and video files you will also need ghostscript and video codecs installed
If you need more help just mail me
cheers
I’m pretty sure I have phMagick working since I am able to use it to resize images perfectly fine.
However, the roundCorners() does not work right. It doesn’t error out, it just doesn’t seem to do anything to the image.
I’m doing this:
$phMagick = new phMagick(‘photo_gallery/tests/test.jpg’);
$phMagick->setDestination(“photo_gallery/tests/finished.jpg”)->roundCorners();
My finished.jpg image is created, but it is identical to the original.
Any thoughts?
I’m using the current version.
@Andrew
use a format that supports transparency (ex: png)