- Digitizing Photos of Whiteboards Using the Command Line ➶
-
-
Make sure you have ImageMagick installed.
-
Save the following somewhere such as
~/code/whiteboardClean.sh
and don’t forget to make it executable withchmod +x ~/code/whiteboardClean.sh
::::bash #!/bin/bash convert $1 -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 $2
-
Add an alias to the above in your
~/.bashrc
::::bash alias wbclean="~/code/whiteboardClean.sh"
-
To convert photo of a whiteboard to a cleaner diagram of the same you can now do:
:::bash cd /location/of/photo.jpg wbclean photo.jpg diagram.png
-
˳ · ˖
Prior entry: Novena Open Laptop
Next entry: Command Line Utility for Generating Books and Exercises Using GitHub/Git and Markdown