Compositing fog in After Effects is surprisingly easy. Just follow these steps!
When it comes to creating fog in After Effects, you actually have a lot of options. Most people prefer to use fractal noise, but I find these methods to be lacking. In my experience I find more luck using the turbulent displace method. But if you have any other suggestions for how to create fog in After Effects, I’d love to hear about it in the comments below.
What Real Fog Looks Like
Let’s analyze a few pictures of fog before we get started.
There are a few takeaways from the above example. Namely, you’ll notice that the areas with fog tend to desaturate, blur, and color the background behind it. You’ll also notice there seems to be more fog-created discoloration in the shadows.
The same is true about this example as well. Areas with fog overlapping tend to be lighter, blue tinted, and blurrier than the areas without fog.
Creating fog in After Effects is fairly simple. Essentially you want to create the right fractal patterns and blur them out in a convincing way. We’ll get to compositing below. Right now, let’s focus on creating the fog.
Creating the Fog
Step 1: Create the Fog Layer
Create a simple white layer (Command+Y) and label it ‘Fog.’ Next, using the mask tool (Q), create a quick circle mask in the center of your composition. I prefer using this method to creating a shape layer because you can easily change the shape of the mask layer if you desire. Feather out the mask significantly (see example above).
Step 2: Add Turbulence
Apply the turbulent displace effect to your shape layer. You probably won’t see a big difference with the default settings. Try bumping up the values until you begin to see some interesting effects. For my example, I have ‘Amount’ set to 205 and the ‘Complexity’ set to 2. All the other settings are default at the moment.
Step 3: Animate the Fog
If you scene calls for fog to remain still, then you can skip this step, but if you want to give your fog an extra level of realism, you probably want to add a little movement to it. How much movement all depends on your frame. To do this, simply set keyframes to both the ‘Offset (Turbulence)’ parameter and the ‘Evolution Parameter’. In my example, I have the fog moving to the right at 30 pixels a second and the evolution progressing at an amount of 20 per second.
Step 4: Duplicate the Turbulence
If you want simply fluffy fog, then you can skip to the compositing process. But if you want your fog to look more wispy or have wind effects applied to it, you should follow the next two steps.
Duplicate the turbulent displace effect. In the new effect, simply increase the amount by around 50 and reduce the size by about the same. Drop the complexity to something around 1.5. All of this depends on the look you are going for, but, for our example, these are the settings we are going to use. You can also cut down on the wispiness by applying a gaussian blur as needed.
Step 5: Simulate Wind
Now comes the fun part. If you manipulate both ‘Offset (Turbulence)’ and ‘Evolution’ with new values, you can simulate wind! It’s a really simple and cool effect that can produce some interesting results if you mess around with it. For further control, you could even parent the ‘Offset (Turbulence)’ layer to a null object or even apply a wiggle effect to simulate swirling winds.
Compositing Fog in After Effects
Step 1: Adjust the Position and Scale
Simply put, move your fog layer to the correct position in your composition and use the scale feature to scale your layer. Don’t worry — your effect shouldn’t pixelate.
Step 2: Set an Adjustment Layer
Create a new adjustment layer (Option+Command+Y). Next, position your adjustment layer under your ‘Fog’ layer and set the track matte to ‘Luma Matte.’ Your ‘Fog’ layer will disappear. Don’t worry… this is supposed to happen.
Step 3: Apply Effects to Adjustment Layer
In order to create realistic fog, we will want to make sure that the fog is not only colored, but also that it affects the layers underneath it. In order to do this we will probably want to desaturate, blur, and slightly color the background layers where the fog overlaps.
In our example, let’s apply a quick Hue/Saturation effect to the adjustment layer. Let’s turn the saturation down to -50 and the lightness up to 20. You should now begin to see your fog layer showing up. Now let’s add color.
My favorite effect to use when compositing is the curve effect, so let’s go ahead and add it. Now, it all depends on your color grade, but in most circumstances you will only want to affect the blue channel. Switch to the blue channel and grab the bottom left point and bring it up to [.9,1.2] (see image below.) Your fog should now have a little bit of a blue tint in the shadow areas and less in the highlights. This is exactly what we want.
The way you color will all depend on your scene, but in general you will want to always bring up the shadows and potentially bring down the whites if the scene is darker.
Lastly, add a gaussian blur to your adjustment layer. A value around 5 should do.
Step 4: Mask the Adjustment Layer
Mask out areas for the fog to sit behind. In our example I’ll go ahead and simply mask out the hill in the foreground.
Step 5: Duplicate as Needed
For the best results, you can duplicate your ‘Fog’ and adjustment layer multiple times to create more realistic effects. A great way to sell your composite is to create a parallaxing effect where the foreground fog moves faster than the background fog, but it just depends on your individual scene and time constraints.
Step 6: Track If Needed
If your footage has some movement in it, you can track it and apply the information to your ‘Fog’ Layers. You don’t need to apply the data to your adjustment layers, just the ‘Fog’ layers.
Now you’re done!
For more information on this technique, I highly encourage you to check out a few of the following resources: