Version 4.3.0
This commit is contained in:
1 parent
96997ddd8e
commit
fe1acf984a
1349 files changed
+116159
-67711
No files matched your search
@@ -54,18 +54,18 @@ class _Imagemagick extends \IPS\Image
|
||||
try
|
||||
{
|
||||
$this->imagick = new \Imagick( $this->tempFile );
|
||||
|
||||
/* Set quality (if image format is JPEG) */
|
||||
if ( in_array( mb_strtolower( $this->imagick->getImageFormat() ), array( 'jpg', 'jpeg' ) ) )
|
||||
{
|
||||
$this->imagick->setImageCompressionQuality( (int) \IPS\Settings::i()->image_jpg_quality ?: 85 );
|
||||
}
|
||||
}
|
||||
catch ( \ImagickException $e )
|
||||
{
|
||||
throw new \InvalidArgumentException( $e->getMessage(), $e->getCode() );
|
||||
}
|
||||
|
||||
/* Set quality (if image format is JPEG) */
|
||||
if ( in_array( mb_strtolower( $this->imagick->getImageFormat() ), array( 'jpg', 'jpeg' ) ) )
|
||||
{
|
||||
$this->imagick->setImageCompressionQuality( (int) \IPS\Settings::i()->image_jpg_quality ?: 85 );
|
||||
}
|
||||
|
||||
/* Set width/height */
|
||||
$this->setDimensions();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user