set resolution of pdf to 72dpi, using 36dpi will not allow previes wider than 298px

This commit is contained in:
Uwe Steinmann 2022-12-08 14:45:31 +01:00
parent 291b62eeb2
commit 56bd5c00e4

View File

@ -50,8 +50,12 @@ class SeedDMS_ConversionServicePdfToImage extends SeedDMS_ConversionServiceBase
$imagick = new Imagick();
/* Setting a smaller resolution will speed up the conversion
* A resolution of 72,72 will create a 596x842 image
* Setting it to 36,36 will create a 298x421 image which should
* be sufficient in most cases, but keep in mind that images are
* not scaled up. Hence, a width of 400px still results in a 298px
* wide image
*/
$imagick->setResolution(36,36);
$imagick->setResolution(72,72);
$page = 0;
if(!empty($params['page']) && intval($params['page']) > 0)
$page = intval($params['page'])-1;