Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

A photo to vector 'scribbled line' algorithm

I would like to build an algorithm that turns a picture into a scribble line that resembles the original picture. An example would be this: enter image description here

into this:

enter image description here

The second image is drawn by hand with one stroke. I am not sure where to begin experiments. My intuition would be to desaturate the image and simulate "drawing" a line with some quasi-randomness that draw more lines in places where the image is darker.

Ideally what I would like to get is a vector image in the end with one path.

Thank you

Disclaimer: I have already asked this question on dsp.stackexchange 3, but there was no answer. I am not sure if that was the right place to ask.

I realise this is not purely programming question, but maybe someone can point me in the right direction?

like image 308
Kuba Misiorny Avatar asked Jun 16 '26 15:06

Kuba Misiorny


1 Answers

Try this ... not mine, but pretty neat. The 'files' tab of the code page contains the original image file. Processing is a fun language for doing this kind of stuff :-)

https://www.openprocessing.org/sketch/486307

like image 97
Charles Morrice Avatar answered Jun 19 '26 21:06

Charles Morrice