mzucker / noteshrink

Convert scans of handwritten notes to beautiful, compact PDFs
https://mzucker.github.io/2016/09/20/noteshrink.html
MIT License
4.81k stars 351 forks source link

Convert the result to vector graphics #35

Open ao2 opened 6 years ago

ao2 commented 6 years ago

Hi,

depending on the input, the output may be shrunk even more when converted to vector graphics, as you also noticed in https://mzucker.github.io/2018/05/14/maptrace.html :)

Here is a quick and dirty example: ./noteshrink.py -e ".pnm" -P "convert %i %o" -c "potrace -b pdf -o %o %i" examples/tree.jpg

Maybe the example can be added to the README?

Unfortunately potrace only supports binary images.

Ciao, Antonio

lgarczyn commented 5 years ago

Inkscape can batch process images to vector graphics, however the svg format is notoriously heavy, being text based.