Working with material IDs

- [Instructor] In this video,we're going to take a look at creating a layer groupthen masking that based on a material ID.So here to start,I'm just going to look at my grip underscore barreltexture set.And so here I don't have anything enabled herein my layer stack.And so what I'm going to do is just come over to my layer stackand I'm going to click the Paint button iconto create a fill layer.So now we have a fill layer.Let's take a look at our shelf here,and let's come over to our materials,and here I'm just going to use this cobalt pure.

So I'm just going to just left-click,and that is going to just fill the channels herein that fill layer with the preset valuesfrom this metal material.So here I'm looking around in the view port,again Shift right mouse buttonjust to kind of rotate the light around,here's kind of the metal texture that we have.Now the idea behind this work flowis that we have this single texture set,now remember this texture represents a materialthat we create in our 3D program.And when that model is imported here into Painter,that material ID is created into a texture set.

Now within this texture set though,we're going to end up creating different kind ofmaterial group sections.So right now, I have a metal,and that's going to work here for kind ofthis barrel muzzle area,but it's not going to work here for this grip.And I may want to have a different metal for thesebolts and screws and such.So right now we have this fill layer,and it's just filling everything herewithin this texture set.So here I'll double-click to edit this layer,and we'll just call this Base Metal for now.So what I want to showcase nowis kind of this start of the workflowthat we'll end up using throughout the rest of this course.

So what I do in this situation, I have my texture set.And what I want to do is break my layer stack upinto what I call material groups.And I'll do that using a layer group.So what I'm going to do here at the layer stackis come all the way over here to this folder icon,and I'm going to click to add a folder.And now I can take this layer, I can select it, left-clickand drag and drop that right here into the folder.And so here, actually I'm going to call this Metal,and this fill layer, I usually use this naming convention,I just called is Base.

Because this is kind of the base start of my materialand then as we kind of showed in the previous video,we're going to start to kind of layer on top of that.So here we have this layer groupand I can click the folder iconto minimize this group or expand it hereby again just clicking that folder icon.Here I have this little circle icon,if I just turn this on and off,that's going to turn the visibility off for the entire group,so within this group I'm going to end up having multiplelayers with this.So what I want to do at this stage hereis I want to set up a mask for this main layer group.

And there's a couple ways that we can do that.So one of the ways is with the layer group selected,I can right-click and I can choose to add a maskwith a color selection.So that's one way.Another way is just to come over here to this Mask button,I can click this, and I can choose againadd mask with color selection.Either way is fine, I typically just use the right-click.So right-click, add mask with color selection,so we do that,and you can see here that it creates this iconor thumbnail here, which is all black,and that's going to be our mask view.

And we can actually move between these two modes,and it's kind of important to think of it that way,like a mode.So right now we have mask mode, and you can seethat we have this slight kind of white outlinearound this mask.And that means that that is what is selected.If I come over here to this kind of swatch areaand I left-click,you can see now I get this blue outline,and that means I'm in kind of the layer mode.So this is layer mode, and this is,we'll click again here on the mask, this is mask mode.

And these two modes are different.We cannot copy and paste,or move data between these two different modes.So now you'll notice that we have our mask.And underneath that mask,you'll see that we have this color selection added.And so really all this is is a shortcut,so here with this effect here, I'm just going to come overand I'm going to click this X button here and get rid of it.So now I just have a mask.If I come over here to this Add Effect button,well here's the effect here as well,add color selection.So really all we're doing is a short cut to creating a mask,and adding a color selection.

If I wanted to do this manually,here's what it would look like,let's kill that effect,let's right-click on this mask,and here I'll just choose remove mask.So here, just to do this manually,we could right-click,we could choose add a black mask,so there's also an option to add a white mask.Now in Substance Painter, black denotes transparency,and white denotes opaque.So we want this to be transparent,so that's why we would choose a white mask.So here we've added the mask, the mask selected,we're going to click this effect button,and we're just going to choose add color selection.

So again, same thing that we've done there.It's just a shortcut by just usingadd mask with color selection.So now that we have color selection selected,if I come over here to the Properties,it's context sensitive,so you can see that it's properties for the color selectionthat we have selected.Here we have this ID Mask.Now this ID mask is going to be automatically setbased on the ID mask that is set here in my additional maps.If I did not have an ID map here in this additionalmap input slot, then this would be blankand none of this would work.

Or I would have to manually add the ID mask.If for some reason that ID mask is not set herebut I do have a texture that I want to use as an ID mask,maybe it's not something I baked,maybe it's something that I paintedin a different application.I could import that as a resource, click this button,and just browse for that texturethat I want to use as my ID mask.Here in this case, it's automatically assignedbecause we are using a ID Map that we baked.Okay so, now we have that set,all I have to do is just click this Pick Color button,and when I do that, the view port then is set into thatadditional map viewing mode, and it's set to IDas you can see here in the top left corner.

And now I have this little picker iconthat allows me just to choose the colorthat I want to add as the mask or the ID.So this pink is kind of what I set up in my 3D programto represent where I want to place the metal areason the mesh,so all I have to do is just left-click this pink area,and you can see that we've now masked this layer group herebased on that ID mask.And if I had multiple areas, I could pick those as well,so here we have one pick.

If I click this picker again,and this time I'ma use this green as well,it's going to represent another metal.I'll just click this.And now you can see that we have pink and greenfrom the ID mask, both of them kind of blend or mix togetherto create this mask.And here if we rollover our mask,we can see kind of a thumbnail preview of what that mask is.Another shortcut to that is if I hold down the Alt keyand left-click on this mask,it then is going to showcase the mask here in the view port.So right now it's showing everythingand that's a little confusing,so let's come over here to our texture setand just solo that grip barrel.

Now this is actually more accurately showingthe mask that we just created here.And if I want to go out of that mode,I can just hit M on the keyboardto go back to my material mode.And then here I'll un-solo that.So this here allows me to quickly maskbased on that ID, and like I said,when we covered this ID bake here a couple videos backin the baking section,you can see where creating or baking an ID map like thisreally speeds up the process of masking.Now in the next video, we're going to take a look atmanually masking some areas without using an ID mask.

Resume Transcript Auto-Scroll

Author

Released

12/23/2016

These days, nearly every AAA game studio uses Substance Painter, making it the industry standard for physically-based rendering material authoring. In this course, Wes McDermott takes a beginner's look at Substance Painter by walking you through a basic project—texturing a weapon asset. He starts with the basics, showing you how to create a project and import assets, as well as use the integrated baking system. Next, Wes shows you how to work with materials and layers, and provides a primer on the brush tool set. After you finish tackling the fundamentals, Wes shows you how to fully texturize a weapon asset, step-by-step. He wraps up by showing you how to create portfolio renders using Iray, the integrated path-tracing renderer in Substance Painter.