Capture PHP Image Compression Quality Level

Asked

Viewed 23 times

0

I need to capture the quality level of an image, I found something relative in [Imagick][1]

Attempted use:

    $img = new Imagick();
    $img->readImage( $local_da_imagem );
    print_r( $img->getCompressionQuality() );

but, this return is always 0

1 answer

1


Solved

$img = new Imagick();
$img->readImage( $local_da_imagem );
echo $img->getImageCompressionQuality() ;

Thus the level of image quality is returned, going from 0 to 100, the higher, the better the quality.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.