Cleaning scanned pencil drawings
Posted by Zumbs on March 28, 2013
Like many other role-players, I habitually draw illustrations for my games. As a player it could be an atmospheric drawing of my character, the party or some situation. As game master it could be a map, an illustration of a location, a symbol or something else entirely.
These illustrations can be scanned and used for a variety of purposes. However, when looking at the scanned drawing, it soon becomes clear that there are all sorts of artifacts on the image, not put there by your pencil. This could be due to the texture of the paper, using an eraser or even coffee-stains gained by the rigors of play.
Cleaning the drawing up by hand is a long and tedious process, so some way of automating it would be very useful. Fortunately, sophisticated image processing programs are able to automate some of the work and assist in the rest.
In this post, I will be using the GNU Image Manipulation Program (GIMP) as it can do the job, is free and available on multiple platforms. If you do not already have it, please download and install it for your platform. GIMP 2.8.2 is used in this post, but I’m sure the same functionality will be available in later versions of GIMP.
The image below is comprised of three images, a part of a map, a drawing and some text to illustrate how to clean up. The image is black and white, but the technique discussed below can be used on color drawings as well.
It should be noted that the drawing contains a lot of dirt from eraser usage in the text portion. This will result in manual work later, however, if your drawings do not contain all that dirt, the technique shown below will be both easier and the result better.
After opening the image in GIMP, select the Colors drop-down from the toolbar. The tools we will be using in this tutorial can be accessed by selecting the Levels… and Curves… items.
Start by opening the curves tool. This results in a window popping up:
The colored graph to the right shows the dirt in the image. If you grab the curve with the mouse cursor and move the cursor to the bottom right corner, you will note that the image turns very dark, with the paper texture painfully obvious, as seen below:
Press Cancel to close the curves dialog. Select the levels tool from the Color menu:
Again, you see a graph that shows the dirt in the image. With the levels, you can remove most of the dirt by moving the white slider at the top to the left of the dirt. Note that if is moved too far to the left, you may loose important details.
The tool changes the color level so that you can redefine where white should be. All colors to the right of the white marker are treated as white, and all colors to the left are made brighter. The point is that much of the scanning artifacts are very bright, i.e. close to being white, so by redefining where white is, you can make them go away.
Press OK to accept, and open the curves tool again.
Like before, grab the curve and pull it to the bottom right. The lines and pencil strokes become very dark, but the paper texture has disappeared. In fact, you can now see the remaining artifacts clearly as shown below:
These are few and can be removed by hand. Also note that you can manipulate the darkness of the image to your own preference. If the drawing is a map, you may want to make the lines as clear as possible, so it should be dark. On the other hand, if it is a drawing, you may want to keep as many of the gray tones as possible.
If you want to remove the remaining noise from the not-so-dark image, you can add the dark image as a separate layer and use this layer to decide where to use the eraser. There are numerous tutorials on layer manipulation in GIMP out there, awaiting to be perused at your leisure, if you want to investigate that avenue.
This entry was posted on March 28, 2013 at 17:15 and is filed under Roleplaying games. Tagged: GIMP, pencil drawing, postprocessing, scanned drawing. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.