Bitmap to SVG

Creating an SVG from a bitmap is pretty easy in Inkscape. Copy and paste your bitmap into a new Inkscape file, select it, do

path -> trace bitmap

import_png

trace

(I used the default options)

The new trace is exactly on top of the original – select and move it

double

path -> stroke to path

stroke2path

path -> simplify

Then go to node edit tool and delete the ones you don’t want by hand.

nodes

However for a plain black on white drawing, this gives you a double line, and in my case, it had no fill, so no way to recreate the line as it was in the original diagram. Or it defeated me anyway.

double1

So I used Gimp to export the png image as .ppm format,

ppm

and then you can do:

brew install potrace
potrace -s cat_black.ppm -o output.svg

Then open the output.svg in Inkscape and edit it as before – this time I got a filled double line.

outputsvg

And I was able to delete the inner line of the outline of the cat, but keep the fill for the whiskers and eyes (this was to export as a dxf for laser cutting).

final