GIMP Guru

FilmGrain

Simulating Film Grain with The GIMP

Before After

One of the much-touted advantages of digital cameras over film cameras is (at least at reasonable ISO levels) a silky-smooth absence of grain in your images. Graininess in traditional film prints or film scans is due to several contributing factors (see the additional reading links at the bottom of this article for details). With digital you can of course get film grain’s counterpart, sensor noise. Although I usually want to reduce noise in my digital images, sometimes I want that gritty, art-house/street-photography/high-ISO grainy film look, especially in monochromatic photos (think Tmax 3200).

In this tutorial I’ll show you how to add simulated film grain to your digital images using the GIMP. To get an idea of what I am talking about, examine the before and after images above, comparing the wall, jacket, hat and face closely.

The Procedure

As with many of the other tutorials on this site, the beauty of this method is in the use of layers. The grain is added to a second layer in Overlay mode; the original image remains unsullied in its own layer.

Load your image into the GIMP. If you are looking to make a B&W image from a color image, you will first want to convert it to B&W. Note that you will need to convert the image back to RGB mode for this technique, however…I thought this portrait of a good-natured street musician might work well with some grain.

Be sure to work on a duplicate (Ctrl+D) of your image because we’ll need access to the original ungrainy image a little farther on…

Double-click on the foreground color icon (the black square, see right) in the GIMP toolbox to bring up the color selection dialog. Dial in the color Red=128, Green=128, Blue=128 and click OK; this should make the foreground icon a neutral gray, as shown at right.
Bring up the Layers dialog (Ctrl+L) and click on the new layer icon (). In the New Layer dialog, name the new layer “Film Grain”, select Foreground as the fill color, and click OK.You should see your image obscured by the new gray layer. In the layer blending mode drop-down box of the Layers dialog (see Layers dialog at right) select Overlay. Now you should see your image again.
With the Film Grain layer selected in the Layers dialog, bring up the Scatter HSV filter (Filters/Noise/Scatter HSV). This filter will add a noise pattern to the neutral gray layer, which will overlay on to the image below.Here’s a not-too-technical interpretation of the filter parameters for the purpose of creating grain:

  • Holdness: Think of this as the “fine-tune” control for the granularity and intensity of the grain. Adjust this after you’ve made a change to the Value control. Higher amounts make the grain finer and less noticable.
  • Hue: If Saturation (see below) is set to 0, this has little effect other than to change the (random) pattern of the grain. I usually leave this set to 0.
  • Saturation: Set this to 0 unless you want to add colored grain (e.g. for a color image). If colored grain is what you want, then adjust this as well as the Hue control.
  • Value: Think of this as the “master” control for the granularity and intensity of the grain. Increasing this will increase the contrast in the grain and the cluster size of some of introduced noise, making the simulated grain seem larger and darker.I recommend that you gradually increase this from 0 upwards to where you see a desired intensity in the preview window and then adjust the Holdness parameter up from 1 to see the effect it has.

Play with the parameters until you’ve got an interesting grain pattern in the preview window of the filter, then click OK. When the filter finishes you should see your image take on a grain pattern.If you don’t like the look, Undo (Ctrl+Z) and reapply the filter with different settings (Shift+Alt+F). Don’t worry too much if the grain seems a little too noticable, because the next step will soften it.

Optionally, apply a bit of gaussian blur (Filters/Blur/IIR Gaussian Blur) to smooth the grain a little. Note that if you use anything other than a very small blur radius you will counteract the effect of adding the grain in the first place, and you’ll end up with a noisy, but not noticably grainy image…so go easy.A value between 1-3 should be sufficient, and then only if you used a high Value setting in the Scatter HSV filter. If you like the grain the way it is, skip this step.

If you don’t like the look after this filter finishes, Undo (Ctrl+Z) and reapply the filter with different settings (Shift+Alt+F).

Although you can stop at this step with good results, I often like to go a couple steps further…

Normally, film grain tends to be most noticable in the midtones, and much less so in the shadows and highlights. We can add a layer mask to control how the grain pattern is applied to the image to accomodate this observation.Right-click on the Film Grain layer and select Add Layer Mask. In the Add Mask Options dialog, choose White (Full Opacity; Note: what you choose here doesn’t actually matter, we’re going to paste over it anyway).

In the Layers dialog, click on (select) the Background layer. Go up to the image window, select all and copy (Ctrl+A then Ctrl+C). In the Layers dialog, click on the layer mask icon in the Film Grain layer (the little white square). Then go back up to the image window and paste (Ctrl+V)

In the Layers dialog, click the Anchor button to anchor the pasted image into the layer mask.

With the layer mask still selected (it should be, if you just pasted into it), bring up the Curves dialog by right-clicking in the image window and selecting Image/Colors/Curves. Click to add a control point in the middle of the linear graph. Then grab the right (upper) endpoint and drag it down to the lower right bottom as shown at right. What you are doing is “half-inverting” the layer mask: making all highlights into shadows so that the midtones are the brightest part of the image. If you’re grain seems too subdued, you may want to drag the midpoint up a bit to raise the brightness of the midtones; watch the image window as you are adjusting this to see the effect on the grain. When you’re all done click OK.To more clearly see the effect of the layer mask, hold the Control key and click on the layer mask icon in the Layers dialog: a little red outline should display around the icon and the image window will change to show the blend without the effect of the layer mask. Control-click the icon again to toggle the effect of the mask back on. With the layer mask active, you should see a subtle difference in the way the grain shows up in the shadows and highlights and overall the grain is more subdued than without the mask.

You may prefer to do the grain blurring step last. Just be sure to click on the grain thumbnail in the Layers dialog before you apply the filter; otherwise you will just be blurring the layer mask!

If you want to do further image editing on the image it might be a good idea to save your work under a new name at this point, or duplicate the image (Ctrl+D) and flatten it (RC/Layers/Flatten Image). If the GIMP had adjustment layers, we’d just create one of those to continue with further enhancements, but lacking that it’s a good idea to give yourself a “checkpointed” result that you can start over with if further edits go awry. You can experiment with changing the hue and saturation, punch up the contrast with levels and curves, or do any other necessary edits at this point on the flattened version.

Tips

  • You can adjust the opacity of the Film Grain layer using the slider in the Layers dialog. This is an easy way to reduce the intensity of the grain and fine-tune the result quickly.
  • You can tweak the curve for the layer mask to similarly adjust the intensity of the grain, but with the added ability to control by areas of tonality, as we did.
  • You can use Levels, Curves or any other adjustments on the Film Grain layer to finesse the grain look. Experiment!
  • Try using a different shade of gray or even a color in the Film Grain layer.
  • The Noisify filter (Filter/Noise/Noisify) also works well for adding simulated film grain. It is a little more flexible if you are looking to add colored grain (you can pick the amounts of red, green and blue components in the noise). For monochromatic grain I think the Scatter HSV filter is a little easier and better.
  • As the third example below shows, this technique can easily be combined with others shown on this site, like sepia toning, vignetting, etc. etc.

Other Examples

Original:
With Sim-Grain:
Original:
With Sim-Grain:
Combining multiple techniques:

Further Reading on Film Grain

Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: