I scanned a line drawing and extracted the line work in Inkscape. I'm trying to clean up the image in Gimp (erasing dust specks and such), but the lines remain a bit jagged. I've tried selecting the lines, shrinking the selection and deleting the rest and I ended up with the result below. I read that blurring and sharpening could work, but it doesn't seem to do much for me? It's not an issue of pixelated edges, for which I found several solutions online. If anyone knows other things I can do to make the lines look a bit smoother, I'm happy to try out those ideas!
Another simple Gimp solution:
Threshold the image
Apply a Gaussian blur so that the irregularities disappear (radius around 10):
Use Curves to restore sharp and smooth edges:
- Drag the foot of the diagonal to the right to restore the width of the lines
- Drag the top of the diagonal to sharpen the edges
Cleanest possible lines can be got by redrawing simple enough paths manually on your scanned drawing. If the creator of the original image does it the result can well be acceptable also as a piece of art. I skip it, because I actually do not know what's wanted. If someone else with no artistic idea tries to redraw your image the lines and curves can easily be a incompatible - no common style, like everyone was taken from a different image.
Median filter (GIMP, Photoshop) can remove excessive details. It leaves easily grey remnants at the edges, but one can remove them by increasing the contrast by applying Curves. This is your scanned image still as bitmap, but after median filtering and contrast boost:
One way to make it look more solid is to let a filter remove all curves. The next version is the previous one + Photoshop's Cutout Filter. GIMP has the equivalent if one install's the G'MIC filter collection (see NOTE2):
The corners can be smoothed in Photoshop by selecting the black, refining the selection with high degree of smoothing with big radius and by filling the selection in a new layer:
If the version which had got median filtering and contrast boost is traced in Inkscape, the result obviously is quite the same that you already have:
In the left there's a traced image and in the right the number of nodes is reduced by applying Path > Simplify. Unfortunately function Simplify does not have other idea than reducing the number of nodes, it's not trying to make the image to look like it's drawn by a somehow more steady hand.
We can make the curves stylistically more uniform by selecting all nodes with the node tool and then making every node to a corner point:
Then we can restore the smoothness uniformly with path effect Corners fillet/chamfer:
Redrawing it in Inkscape manually is the suggestion I prefer, if the image really must be converted to a vector drawing and remove all traces of traditional painting. As said, it's done best by the original artist.
The 2nd best would be a person who has some sense of the wanted style. The rest of us would draw a little too easily something like this:
NOTE2 I'm afraid nothing makes it nice and smooth at the same time automatically. But you have also another direction. Make it more complex. An example:
The leftmost version is your scan filtered with G'MIC collection filter Artistic > Cubism. In the right the left one has got a Gradient Map.
As you see, there's no limit to get more and more weird results by splashing together more effects. But the original artist is needed to say what supports his idea.
A rather simple solution, all in Gimp:
- Threshold the image
Filter > Blur > Median blur(radius around 10):
If you want to go further:
- Obtain a selection (Color-select the black), and obtain a path from it
- use this clever script to simplify the path
- recreate the image by obtain a selection from the simplified path, and bucket-filling the selection