setimageresolution() query
Posted: 2016-06-09T08:31:49-07:00
Hello,
I have written under line of codes to convert image resolution to 300. Below code, does the trick and shows it in the properties of that image file, but when I open the same file in Adobe Photoshop, it shows the original resolution and not the changed resolution.
$image = new Imagick();
$image->stripimage('test.jpg');
$image->stripimage('image300.jpg');
$image->readImage('test.jpg');
$image->setImageResolution(300,300);
$image->resampleImage(300,300,imagick::FILTER_UNDEFINED,0);
$image->writeImage('image300.jpg');
Thanks in advance!
I have written under line of codes to convert image resolution to 300. Below code, does the trick and shows it in the properties of that image file, but when I open the same file in Adobe Photoshop, it shows the original resolution and not the changed resolution.
$image = new Imagick();
$image->stripimage('test.jpg');
$image->stripimage('image300.jpg');
$image->readImage('test.jpg');
$image->setImageResolution(300,300);
$image->resampleImage(300,300,imagick::FILTER_UNDEFINED,0);
$image->writeImage('image300.jpg');
Thanks in advance!