Thursday, January 15, 2009

VFX Tip #3 - Compositing Fog or Mist

Compositing fog elements seems like a pretty straightforward thing to do in After Effects. Shoot or render your fog element against black, and then Add or Screen it on top of your footage, right? Wrong. This method is incorrect. Let's go over why.

The Add transfer mode should only be used when compositing light passes, or something that is made up of light, such as fire, lasers, or lens flares. However, fog, as we know, is not made up of light, but rather tiny particles of moisture suspended in the air. They may reflect, refract, and diffuse light, but they do not emit it. Therefore, we must not composite fog elements with Add or Screen because it is an incorrect representation of real life. This holds true of smoke elements as well.

On a simple compositing level, fog elements should occlude their background plate, not Add to it. The following is a technique I use for compositing fog elements into background plates using After Effects. This method can apply to other compositing programs as well, so if you use Shake, Combustion, Nuke, Fusion, or other such program, please continue to read on.

First, let's look at our original background plate...

Click To Enlarge

As you can see, this image provides a good reference for a starting point to add more fog. Notice how the fog completely obsures the top of the bridge tower. The fog is not see through as an Add operation would be. Now, let's take a look at our fog element...

Click To Enlarge

I purchased this fog element from http://www.detfilmshd.com/, which is a great resource for low cost elements that composite nicely into VFX shots. I highly recommend them. If you do not have a filmed element of fog, Fractal Noise or Turbulent Noise can be used as a decent substitute.

Now, we can't just put this element over the background plate using Add, because we get this result...

Click To Enlarge

That doesn't look very natural when we compare it with our original plate. It's blowing out the bridge details and the sky, because it seems to be adding light. This is not what we are going for. Remember, we want occlusion, not addition.

A better alternative, is to create a new soild layer, and use the color eyedropper tool to select an appropriate gray color to use for our fog. I generally try to use a color near the horizon.

Click To Enlarge

Now all we have to do, is use the fog footage's luminance as a mask on the new gray solid we just created. To do this, simply layer the fog element footage over the solid, and set the solid's track matte to "Luma Matte." That's all their is to it. Your composite will now look much more natural.

Click To Enlarge

Finally, we can add one more last touch to this composite. Select your background plate layer (in this case, the bridge) and add a Compound Blur. This will look strange at first, so we need to make a couple of adjustments. Set to Blur layer in the Compound Blur controls menu to be the fog footage element. This will use the fog element's luminance as a mask for blurring the background plate. This simulates the way fog in the real world diffracts light behind it. The blur by default, though, will be 20, which is too high for fog, so set it to be around 0.5-1.0.

Click To Enlarge

A little extra work than using transfer modes to be sure, but it will greatly help the realism of your shots. And here is our finished composite...

Click To Enlarge

Tuesday, December 16, 2008

Car Shader Tests

So, this is my first attempt at doing a photorealisitc studio car rendering. I used mental ray for 3ds max for this image. The car is using shaders from the Arch & Design materials, as well as a Car Paint material build with mental ray.

A little post work, such as film grain and softening, and I think it's starting to take on a realistic appearance.

Click to view full resolution image


Click to view full resolution image


Wednesday, November 26, 2008

Tutorial : Filmic Fades and Dissolves


Some of you may or may not be aware, that when you fade or dissolve film optically, it produces slightly different results than when you do the same operations in computer software.

In non-linear video editing, a dissolve or fade is done in software, by interpolating gradually between the RGB values of each pixel of the image. In this tutorial example here, which is a fade, it is done by interpolating the RGB values of the image with black.

In film however, this effect is created by controlled double exposure from frame to frame; transiting from the end of one clip to the beginning of another, or by fading to black. Doing it in this way, in essence, causes lighter parts of the image to win out over the darker parts of the next clip.

The difference is very subtle, but the difference can be detected almost subconsciously, and most people prefer a filmic or optical dissolve.

In this tutorial, I choose to illustrate a fade to and from black, because it is seen often in movie trailers, and you can view more examples readily by going to Apple Trailers.

This tutorial is made using Adobe After Effects, however, any software package that allows processing of images using a Gamma 1.0 color space should work as well.

So first, here is a video example of the differences between the two dissolve types...


Filmic Fade Comparison from Daniel Broadway on Vimeo.


After watching it, you can see the difference is subtle like I said it would be. Here are a couple of frames to illustrate the fade better. Notice how the light parts of the image win out over the dark in the filmic version, and the non filmic version looks kind of muddy....

Ok, so how do we do it?

In After Effects, load your footage into the timeline. Then create a new black solid by going to Layer>New>Solid... Put this solid over your footage in the timeline. Now to get the filmic look, we have to make sure our project is set to blend using 1.0 gamma. You do this by going to File>Project Settings... Then all you do, is click the checkmark box next to "Blend Colors Using 1.0 Gamma."


Now you will be able to create a filmic fade by simply animating the opacity of the black solid layer. It's that simple.


Well, that's basically all there is to it. Like I said, this can also be done with dissolves, just use another piece of footage instead of the black solid, and you will have a filmic dissolve as well.

Monday, November 17, 2008

Star Trek Trailer 2 Online


The second trailer for the new Star Trek movie is now online. Even if you are not a Star Trek fan, you just might like the look of this new one. They've gone to the roots to start over it seems.

You can now view the new Star Trek trailer online at apple.com here...

STAR TREK TRAILER 2

Monday, July 14, 2008

OpenEXR


I'm very late jumping onto the bandwagon of OpenEXR, or the .EXR format for images. My recent conversion to a completely linear workflow has coaxed me into making the jump. I must say however, that I wish I had been using EXR ever since it came out to the public.

For those of you who don't know, EXR is a image format written at Industrial Light and Magic for storing scanned film images or renders. It is a very sophisticated format, allowing you many options for compression, bit depths, and the ability to store high dynamic range values.

I won't go into all the technical information, but just a couple of suggestions I learned.


1.When storing a render without film grain , compress using ZIP lossless compression.

2. When storing a scanned film frame, or digital video with noise, compress using PIZ lossless compression.


For more techinical details on EXR, see these two sites...

http://www.openexr.com/

http://en.wikipedia.org/wiki/Openexr


The main reason for me posting this entry is this: USE EXR, IT ROCKS.

Saturday, July 5, 2008

Essential Reading For Every Visual Effects Artist

I have been meaning to write a new VFX tip for weeks now, but I haven't gotten around to it yet. Life's been busy...or I've been lazy, I don't know which. Perhaps a little of both, skewing toward lazy.

However, while this is not a VFX tip or tutorial of my own, I hope it is helpful nonetheless. I learned CG by spending hours at the local Barnes and Noble reading books on graphics and visual effects. Today, there is a wealth of knowledge and reference out there regarding these subjects. Here is a list of three books, that are at the top of my list of essential reading for visual effects artists.

This is my favorite book of all time. Never before I have seen so much information about visual effects crammed into one book. None of the material is wasteful, and it includes great tips on compositing, along with explainations on why photographed elements look the way they do. While this book is specifically for Adobe After Effects, the information can be used across almost any compositing package, as it also includes general theory along with detailed examples of how to perform the effects in After Effects. Pick this book up.

2.Digital Lighting and Rendering (2nd Edition) by Jeremy Birn

I know I said number one was my favorite book of all time, but I think this book has to be tied. It's fantastic, but in a different way. While AE Studio Techniques covers a wide array of compositing techniques, this book covers 3D lighting, texturing, and compositing. The first edition of this book almost single handedly taught me how to light CG shots. When I was a visual effects noob way back in 2000-2001, I spent many weekends at my local Barnes & Noble reading that book. The second edition is the latest one, and it covers everything from old school techniques, to the newest of lighting and compositing. This is the best book on CG lighting that has ever been written, period.


I included this book in the list because not only is it clever, informative, and well written, it's just plain fun. This book excited me the first time I thumbed through it. Stu explains ways to get big budget looks on a not so big budget. He covers almost all aspects of filmmaking from your first script idea all the way to the finished product. There is a chapter on effects, which even covers miniatures, along with digital effects. The information in this book is fantastic. Pick it up, and be on your way to shooting a low budget action flick.

Monday, June 16, 2008

Stan Winston Passes Away


It is with great sadness I make this post. Legendary make up and creature effects artist Stan Winston has passed away at age 62. He was one of Hollywood's top talent. Throughout his career, he won three Academy Awards. His loss is a great one to the effects industry, and to Hollywood as a whole.

Some of you might not know his name, but you most certainly know his work. He and his team of talented artist brought us the likes of the Terminator, the Jurassic Park dinosaurs, Alien, Predator, and many more. His most recent work was creating the practical suit for Iron Man.

His death hits kind of close to home for me, because I am an aspiring effects artist. Even though I aspire to be a CG artist, and not a physical effects artist as Stan was, he is still an inspiration to me. His animatronic work on Jurassic Park, along with ILM's CG effects, is what inspired me originally to want to be an effects artist.

So next time you watch one of the classic movies he worked on, remember all the hard work and genius behind the effects that he and his team created. A truly talented man, and a great loss to be sure.