Tags
PHP
Asked 7 years ago
24 Dec 2016
Views 1883
web-api

web-api posted

how to improve quality of image in php

How to improve quality of image in php .
in my website . i had section where people can upload image , some time they upload very low resolution image. and it get stretched / blurred when we show it with bigger width and height .

Mahesh Radadiya

Mahesh Radadiya
answered Nov 30 '-1 00:00

use ImageMagick


function improve_qaulity_image($imagePath) {
    $imagick = new Imagick(realpath($imagePath));
    $imagick->enhanceImage();
    header("Content-Type: image/jpg");
    echo $imagick->getImageBlob();
}


enhanceImage is function to enhance image quality in php
it Improves the quality of a noisy image .
Post Answer