Improve image quality from dvipng without increasing image size?

For dvipng, the -D option increases dpi in the image, but also increases the size of the image, and the -Q option improves anti-aliasing, but not enough. Is there a way to increase the resolution and image quality without increasing the image size?

+4
source share
3 answers

I would suggest that you use -D and -Q , and then post-process the generated image with imagemagick mogrify or something similar to scaling the image back. An external program is likely to do a better job with good scaling.

+1
source

In part, this may be related to the way DVI files are displayed. You may be able to use PDF instead of DVI, which I did when I needed PNG from LaTeX sources.

+1
source

If the -Q option has any effect whatsoever, it means that you are using bitmap fonts, PK fonts. This is the oldest font format available for TeX and will not have real good performance.

I suggest you install FreeType and rebuild dvipng. FreeType has the right anti-aliasing with the right hint.

What system are you using?

+1
source

Source: https://habr.com/ru/post/1299066/


All Articles