2

This is more of a feature request. I am easily able to generate the PNG by calling toDataURL on the returned canvas. But the quality of the image is rather blurry/poor. I did some googling & found out that by default it just returns an image at 96 dpi. And there doesnt seem to be a standard way of improving this. Also the toDataURLHD is experimental and does not work any ways.

Is there any way html2canvas can return an image at a higher resolution? Or even if it can provide a way to get the DOM being rendered, I can use some library that uses the DOM (with all the computed styles applied to it) and then generate whatever image I want.

Shiv Yadav
  • 161
  • 12
  • Possible duplicate of [setting canvas toDataURL jpg quality](https://stackoverflow.com/questions/14383557/setting-canvas-todataurl-jpg-quality) – ChesuCR Sep 16 '19 at 16:49

1 Answers1

0

I am unable to comment so writing answer. @shiv probably you should look the quesiton setting canvas toDataURL jpg quality

sujit tiwari
  • 274
  • 3
  • 14