Implementation of a technique allowing to draw the contour of any image using the Fourier transform.
usage: \
- fourier-draw.py [-h] -i INPUT -o OUTPUT [-f FRAMES] [-N N]
arguments:
-h, --help show this help message and exit
-i INPUT, --input INPUT
input image path
-o OUTPUT, --output OUTPUT
output animation path
-f FRAMES, --frames FRAMES
number of frames
-N N, --N N number of coefficients used
- Input image :
- Output animation :
After the extraction of the contours, I only take the largest one for simplicity. But if we wanted to reproduce more fine-grained details one would need to use all the available contours. In order to do that, we could simply stack all the contours into one big contour but that does not work pretty well since the naive stacking of contours adds more lines which make the final animation cumbersome.
We would like to connect the contours so as to minimize the intersection between the lines.
- https://www.youtube.com/watch?v=r6sGWTCMz2k : But what is a Fourier series? From thermal transfer to designs with circles