Join Steve Wright for an in-depth discussion in this video 074 Edge grading, part of NUKE NUGGETS Weekly.
- [Narrator] Hi, this is Steve Wright, welcome (mumbles) to this week's Nuke Nugget Better Keying Edges with Edge Grading. All too often our beautiful keys are ruined by dark edges or funny colors. Here is a technique that you can use to literally color-correct the edges to better match the background. Now, the setup is I've got to crop out of a 2K film scan here and we're going to pull a key on this and check out our edges. Now, on a hook-up to my Keylight node, I'm doing the comp in keylight and I just pull the basic key; no sweetening of any kind and, as you can see, oh, we've got some funny things going on here; it's some dark edges there and up along this sleeve, so many would try to solve this problem by dilating the key, so let's open this up and show you why that's not a good idea.
When we dilate the key, of course, it's going to lose fine hair detail, so here we go; we'll dilate the key. There we are. Okay. So, this is before and after. That fixed our problem, but we come up here. We look at the hair detail. You could see; we took a haircut in the process, okay. Dilating the key has punched out all those faint semi-transparent pixels around the hairline, so if we can color the edges correctly and (mumbles) dilate the key, we're going to preserve all of our fine hair detail, so let's give it a go.
So, the first thing we'll do is compose it outside of the key light. I'll disconnect the background. I'll add a merge node here. Bring down my background and hook it up there, so now we're compositing outside keylight and this gives me a chance to intervene between key light and the comp and, of course, we still have our terrible dark edges. Alright, so, all I'm going to do is select this keylight node here and branch connect the blur node with the shift + B and I'm going to tell the blur node that I want to blur just the alpha channel by just a small amount; by two.
I'm going to use the key from the key here as a mask for color correcting the outside edge, but I'm going to blur the key just a little bit, so it'll bite into the interior a little more. It kind of spreads out that edge for me. Alright, so, let's hook up the (mumbles). We'll check our alpha channel and if I don't let on and on, you can see there we go. Okay, back to RGB. Next, I'm going to hook up a grade node right here and hook up the mask input to the blur.
Okay, so now, if I hook my viewer up to this grade node; let's push in and I'm going to just blast the gain up and you can see it's masked by the; it's on alpha channel, so it's gaining up the whole thing, but if I say the mask is the alpha channel inverted, now only the outside edge is going to be affected like this. You see, the interior is not affected at all. That's what I'm looking for.
Alright, so we'll come back to our comp, re-home in the viewer, push it a little bit there. Okay, so, here is our edge. There's our nasty edges. We're all set up. So, I'm going to gain up the edges. See that? I am disappearing the nasty colors there. We can also throw in a little gamma. Okay, now, very important point. Look at this grade node here. Clearly, we have a premultiplied input.
We have to tell the grade node that we want to unpremultiply by our alpha channel, okay? This is important, so I'm going to say: "Unpremultiply by alpha", okay? And, if we push in, we can see that it'll have an effect on our edges, okay? We do not want to be color-correcting premultiplied images willy-nilly. Okay, so, back to the comp. Alright, now if can't quite reach some of these pixels here, what I want to do is I want to broaden the edge of my blurred key here, so I can go to the blur node and maybe increase the blur size, cause every time I do this, this will allow my color-correction to cut deeper into the edge, okay? So, there we go.
So, we'll go back to our comp, restore our color and now, let's see if we can twiddle away the last little bits there. Okay, a little bit of gamma, a little bit of gain. Now, don't try to clear up every last scrap of your discolorations, because if you do an edge blur, the edge blur will get rid of the last little bits, so let's throw that within the mix here, select merge node, go to filter tab in an edge blur.
And even though, this is a 2K, I like to have the edge blur set on the smallest possible number that will do the job and so, look at here, if I turn this off, you see there's a little residual discoloration and the edge blur mocks it out. So, there you have it. Better keying edges with edge grading. If you'd like to see all my new courses on LinkedIn's lynda.com, just do a search on my name, Steve Wright. Be sure to check in next week, so you don't miss out my next Nuke Nugget.
What kinds of NUKE tips do you need? Join the Steve Wright's NUKE NUGGETS group on LinkedIn, and post your requests there.
Skill Level Intermediate
Q: Why can't I earn a Certificate of Completion for this course?
A: We publish a new tutorial or tutorials for this course on a regular basis. We are unable to offer a Certificate of Completion because it is an ever-evolving course that is not designed to be completed. Check back often for new movies.