When I use the following ghostscript command to create jpg thumbnails from PDF files, image quality is often very poor:
gs -q -dNOPAUSE -dBATCH -sDEVICE=jpeggray -g465x600 -dUseCropBox -dPDFFitPage -sOutputFile=pdf_to_lowres.jpg test.pdf
In contrast, if I use ghostscript to generate high resolution png and then use mogrify to convert high-res png to low-res jpg, I get pretty good results.
gs -q -dNOPAUSE -dBATCH -sDEVICE=pnggray -g2550x3300 -dUseCropBox -dPDFFitPage -sOutputFile=pdf_to_highres.png test.pdf mogrify -thumbnail 465x600 -format jpg -write pdf_to_highres_to_lowres.jpg pdf_to_highres.png
Is there a way to achieve good results bypassing the intermediate step pdf → high-res png? I need to do this for a large number of PDF files, so I'm trying to minimize the calculation time.
Here are the links to the images mentioned above:
source share