We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi,
Just a suggestion for the Imagick implementation in imagecow. Specifically, in Libs/Imagick.php, on line 229 where it uses scaleImage():
if ($this->image->scaleImage($width, $height) !== true) { https://www.php.net/manual/en/imagick.scaleimage.php
if ($this->image->scaleImage($width, $height) !== true) {
ScaleImage() does not allow configuration of the filter or blur setting. The function resizeImage() is very similar but allows for changing these settings. https://www.php.net/manual/en/imagick.resizeimage.php
For example we set the filter to Lanczos, and blur to 0.8: if ($this->image->resizeImage($width, $height, \Imagick::FILTER_LANCZOS, 0.8) !== true) {
if ($this->image->resizeImage($width, $height, \Imagick::FILTER_LANCZOS, 0.8) !== true) {
This vastly improved the quality of resized images. Especially ones with text on them.
The text was updated successfully, but these errors were encountered:
Hi, thanks for the suggestion, I really like it! Do you want to work on a pull request? (If you don't want, don't worry, I can do it)
Sorry, something went wrong.
I'll let you do it. :)
changed resize method #45
a5228d9
No branches or pull requests
Hi,
Just a suggestion for the Imagick implementation in imagecow. Specifically, in Libs/Imagick.php, on line 229 where it uses scaleImage():
if ($this->image->scaleImage($width, $height) !== true) {
https://www.php.net/manual/en/imagick.scaleimage.php
ScaleImage() does not allow configuration of the filter or blur setting. The function resizeImage() is very similar but allows for changing these settings.
https://www.php.net/manual/en/imagick.resizeimage.php
For example we set the filter to Lanczos, and blur to 0.8:
if ($this->image->resizeImage($width, $height, \Imagick::FILTER_LANCZOS, 0.8) !== true) {
This vastly improved the quality of resized images. Especially ones with text on them.
The text was updated successfully, but these errors were encountered: