Master Material Basics! Unreal 5 (Must KNOW workflow!)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] all right we're in unreal and we're going to build out a master material and it's going to have some controls for uv tiling for tint for things like turning on how metal the object is maybe turning on and off a emissive component as well as a normal map and a detail more normal map which is great as well as controlling the normal intensity so we've got a set of controls that we're going to build out in addition i wanted to i brought in a i went into bridge and it's really great to take a look at the way that quixo lays out its master material as well so i recommend that so let's get started so we're gonna ctrl shift n and i'm going to create a master matte demo folder and we'll right click create a material called this m underscore master one and open that up we'll dock this up here and let's start out by creating the base color so we can start out by holding down the three key and clicking and this creates a vector3 constant and then you can change the color but this is not a parameter so in order to talk to your material instance or blueprints for example i'll put in links for a quick example that i created for that you definitely need this to be a parameter so the hotkey for that is holding down the v key and we'll call this tint and we are going to then also hold down the t key and create a texture sampler but this is not a parameter and you can convert it to a parameter by right clicking diffuse we're going to combine these two with a multiply nodes holding down the m key and clicking and we'll just connect these up now i'm going to plug in a diffuse texture so a good way to quickly search is just using the underscore d it's a good convention to use then so we can scroll down and pick one that we like let's see i'm going to use the hewn stone or maybe even the rough cut stone if we plug this in right now what are we going to get nothing because if we multiply something that's black you just get black pixels so we can start this out white object just showing off the material now we can probably go from here to show off uv tiling but before we do that anytime we create an area of control i like to do two things i like to comment it so i'm going to hit c and we'll call this color and then also i like to group it so that the color grouping shows up in the material instance so we can actually just copy that and use that grouping as a name so now there's a color group and we can actually just go in here and switch all of these to the color group so that'll show up in the material instance awesome so now let's do uv tiling so to create uv tiling i'm holding down the u key and clicking to create a texture coordinate node and then we're going to create two scalar parameters one for u and for v so i'm going to hold down the s key and we'll call this one u and then we can set the tiling we can start that out at two we also even can give it a group name right uv and then we can duplicate that so ctrl d and we're going to want to call this the v and then we can combine this this two and you need to combine it with an append pen vector so just combine that and then we can just multiply that all together now if we had more time we could put this into like a material function but keep this simple we'll just hit this and call this uv and we can plug that in and you can see that it's already tiling our uvs awesome let's quickly then add a scalar parameter for metal and also we can duplicate that and we can do one for a rough we're keeping it very rough because it's rock and there we go and now let's move on to our normal map we can start out by creating another texture nodes holding down t key right clicking convert that to a parameter i'm just calling this normal now we can also create our group so this is our normal group and we can find the normal map that's associated with the brick cut stone so we can just go under here and just cut and and skull scroll down to brick cut stone there it is we could plug that in just as is and attach it to the to the normal map here that way we are getting the tiling set correctly but i also mentioned in the intro that i wanted to do a detail normal and also i wanted to set up a set of controls so that i could modify the intensity of that detail normal too so let's do that so we can hit ctrl d and duplicate this we can call this normal detail and we can search for detail because there's actually a built-in normal map that's a detailed rocky normal that comes in with the starter content so we'll just use that now the starter content this is actually a 1k map and you can even use a lot lower resolution now we need to combine these you might want to combine them with a multiply but that would be wrong so don't do that you want to do a blend angle corrected normals and that's a function so these these blue nodes if you click in on them you'll actually see it's a little bit of some complicated mathematics but the great thing is that let's go back to our work in progress here the great thing is it's not going to destroy your data we're going to want a set of setup controls for tiling so we can do just ctrl d for that whole process let's grab that and we'll just call this uv tile so we want to put this in as a utile and a v tile or probably detail is better so why don't i do that on both and we can fix that here too yeah much better and then we can take this and we can even make a like a group can just attach it to the normal group as well actually since for this we're keeping this a fast demo so put that because the uv detail is in normal detail we'll tie that there and then we want to be able to control the intensity flatness works pretty well too so i'm going to use flat normal so we can plug that in here and you can do you can do multiple iterations of this if you want so this is looking for a scalar parameter so this like thermal flatness so we can take that and we can say we want it to start out really flat because we want to see so we want to see the difference we want to be able to compare the difference right so we can plug this in this is our normal group and now we can get a little close here and take a look at what this looks like just by itself and then if we if we say that it's not flat get a little bit more detail now what if we dial this up to something like 11 each here right so now we can go and say okay this is what it looks like flattened and so you can see it's bringing out some nice additional detail so there's not flattened and also flat there's ways of like increasing the intensity as well so we could set this at point five zero so here's not flattened and the details we could we could experiment right so if we wanted something like a smaller number of iterations you see a much much more sort of gross detail i would dial it up in terms of i like my detail normals to really give fine detail but for this example let's just keep moving so the final thing that i wanted to do was to add an emissive mask and i wanted to set that up so we could use an additional parameter switch node so we could just show you that possible all right so let's set that up i'm going to duplicate this just to because it's already a parameter we'll also call this um emissive and we'll go in and we'll look for a underscore m and that's a mask node we've got some different choices here i'm just gonna pick this one the chair and this is a a texture packed texture so what does that mean it means that there's a a different grayscale texture mask in the r the g and the b channels so we could just check that out and plug that in and see what we get shining through so now how would we give that a color well we could do the same thing and just duplicate a tint and we could call this like emissive tint emissive tint and we could multiply these together grabbed the g channel right so there we are the emissive tint now if we wanted that to be like just red then we could do that but one of the things you can do also is overdrive to get a really strong glow so we can like go over one just make that really glowy now i also said that i wanted to add a parameter static switch now this is sort of an on off switch and you can then specify that if this switch is set to true then it will be on and then we can set a we just do a zero into false so right now it's and by default it's it's off if it's a static parameter then you cannot control it with blueprints so it's either on or off but you can control it here for sure so it makes an easy way to turn it on and off and then you can also then control the tint color still the thing we didn't do yet is we didn't create an emissive group so we'll do that and we'll put that in the the emissive here we can even put this in the emissive group 2. all right let's hit c and call that emissive all right it's a start for a master material so we can hit apply and now we can create our material instances and apply that to some of these blocks around here and then we can create another instance of it so how do you do that you right click create a material instance and call this starts out mi and then instance and then you can just add that to an object and from there you can open it up and you can specify like how many uv tiles you want do four and four and we could also change the tint and make it a little bit more red if we wanted just a little bit more awesome and then right like we said we could turn off the emissive if we wanted or keep that on or change the color or switch out the normals and so that is that's really wonderful right so and it's also very low cost if you're going to do iterations on this so we can create another and we can do metal and then this metal one we could then drag on here and we could then go in and specify something like hey this is a this is like metallic rock and we can also then change the roughness as well so very sparkly change out the normal map as well we could make this into something like they have a steel yeah they have a steel texture so we'd probably want to dial in the this first steel than normal and let's see how that's looking all right we've got the basics here we've got a set of controls set of material instances so this is a really great start and a really great way to allow yourself to have a set of controls that you can control with blueprints and then you can also do a lot of extra things with this and so i'll put a lot of additional links to ways of doing this with blueprints and also how can you control this also in the sequencer you have to use a material parameter collection but that's more for later all right thanks so much for watching if you like the video give it a like and also come back for more unreal tutorials [Music] you
Info
Channel: Shaun Foster
Views: 13,915
Rating: undefined out of 5
Keywords: Master Material, Materials, Shaun Foster, ShaunReal, Unreal
Id: tT0ANO5sXso
Channel Id: undefined
Length: 14min 31sec (871 seconds)
Published: Sun Sep 18 2022
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.