Worn edges in Blender

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] hey there in this video i'm going to show you how to add procedural edge wear and tear and weathering whatever you want to call it to all your meshes completely procedurally using just a few simple nodes it's really not that complicated and there's a lot of possibility with tweaks and control over your nodes so this is what it looks like and it adds a great level of realism and interest to your models because in the real world objects hit stuff they rub on stuff the paint comes off the metal gets worn smooth and all kinds of other things happen to physical objects in the real world that give them imperfect edges so when you learn to create those in 3d it can really bring your work to a new level so guys i'm almost at 2 000 subscribers which is super exciting so if you haven't already hit subscribe like and please comment now this trick works best on sharp edges so i found this really cool 3d model by this amazing 3d artist named renovox on sketchfab and he's got incredible stuff all for free on sketchfab i download the file i'm going to import it as an fbx file so file import fbx go to my folder with my sketchfab stuff there's a lot of it in here i like sketchfab there it is radial01 all right so this is the model he made now i want to take away all the texturing because we're just going to do the edge shading and you know not the fancy stuff so let's right click on the object here and you can see he's got an image texture which by the way is exquisitely done but i don't want it for this one and i'm going to get rid of the normals just in case it gets in the way and i'm going to flip it on its side so it's going to be easier to see in this video format so with the object selected if i hit the period button it zooms in and centers on that object real quick before we actually make the nodes i need to give you a quick pros and cons of this edge shading technique so the pros first of all it's procedural which is great no images needed very low on memory use it's also completely tweakable so there's a lot of things you can tweak and perfect and add to know what i'm going to show you today is really just the starting point and i am by no means a node master or you know like awesome at any of this stuff i just know a few tricks which is why i'm sharing them so people out there that really know how to use nodes and math and all kinds of crazy stuff that's way beyond me can take what i'm going to show on this video and you know make it 100 times better but uh this is just a basic you know kind of intro video but you can still get good results with it so it's tweakable it's reusable as a shader so if you save this as a node group which is another thing i'll show you at the end of the video how to make a actual shader node group and reuse it later in other files you know you can use it in other files you can use it in other projects i add it to my default blender file so anytime i start a project my node group for edge detecting is there and i can use it whenever i want there's two cons though and they're kind of big the first one is it really only works in cycles which i know i really wish it worked in eevee because ev so fast with stuff like this but uh you can get it to work in eevee but you have to add a whole bunch of extra geometry which is kind of ridiculous and annoying and very problematic with certain models and you have to do the nodes a little bit differently i think to make it really show up because it's just super faint and weak and the second con is that you can only see the results of these nodes in render view so you have to actually be in the rendered view of the viewport for it to be visible if you're in materials view what we're going to do today will not be visible and i don't like that very irritating hopefully in future versions they will incorporate the geometry note a little bit better so let's get to building these nodes so i'm going to switch to shading mode and i've customized this view to basically be like this kind of a half split view my model on bottom and nodes on top so select your object click new material and here we go we're just going to name this edge tutorial and up here is our node tree so hold alt and left click and move over that's how you pan and drag if you have this thing over here in your way just press the letter in on your keyboard and that will go away so let's start by making a geometry node so shift a to get the add menu click on search and just type geo and by the way i'm not going to be using the popular pointiness option i really don't like how pointiness works i found what i believe is a better and easier to use method so we're going to get that in a second next node we need shift a click on search is bevel bev enter put that down there let's make things nice and clean next is a vector math shift a click search v e c going down to vector math right there now we're going to plug in normal to the top there and this normal to the bottom there and we're going to change the math method to dot product now i have no idea what this is doing i really don't but trust me it's going to work all right next is a color ramp shift a click on search type in ram right there connect these to do and we're going to invert this so we're going to switch black and white you can do it manually by dragging these or you can save time by clicking on the down arrow and click flip color ramp there we go and let's switch this to card cardinal which i believe is a little smoother than linear next we need a basic math mode so shift a type in math plug in color to slot number one slot number two make it the number three this is something you can tweak later if you want to but for now we're going to leave it at 3 because it works pretty good put the math mode to multiply okay i promise we're almost done we need three mix rgb modes and this is going to be used to blend in our roughness later and our noise because adding noise to the edges is what's going to give an irregularity and give more realism and creative control so shift a search just type in rgb and we're going to duplicate it times three so shift d put one there and shift d put one there all right let's plug in value to the very first color and make this darken darken color is going to go to slot 2 of the screen rgb mix at the very end and this middle one here that's just set to mix which because we're going to be able to cross here between roughness 0 and roughness 1. we're going to put this color in slot number 1 at the end there now let's add the noise down here and we'll finish it up by making a node group so shift a click on search mus for miss grave or as i like to say musgrave click on the color ramp up here and just shift d i already got one so just move it down here and we're going to make it a little bit longer to give us a little more accurate control drag factor to factor there plug in the color ramp color result into color number two of darken right up there move this back a little bit if you click on a node and hit g you can you know g for grab or you can move it around okay so we're done this is it now we need to turn it into a node group so we can control things and finalize it so i'm going to hit b for box select that allows you to just grab a square kind of like in photoshop and control g or you can go up to node and make group control g so everything turned green what's going on here we can see our nodes in the background and we've got this in the foreground this is basically like a nested group of nodes or a group which is kind of its own self-contained thing if you press tab now i've got this little guy here what the heck is that well it's not finished yet so let's finish it tab to get back into edit mode of that node group now we've got to plug into a few things to this group input so we can actually put in sliders and numbers here and then it'll give us an output afterwards so first thing we need is the radius of the bevel right there that's one thing i love about this method is the radius you have control over the radius very easily with pointiness you don't can you have no control over radius okay next thing is the scale of the noise so click on scale here and drag it to right there now look if i tab again look at this we have controls radius and scale pretty cool moving on down we need uh the noise mix which is this darken slider here right there that'll turn up or down our noise we can add or take away noise next is the factor of this middle mixer which is the mix between roughness it basically just gives us a normal roughness control for our shader and then lastly our factor over here which is going to add the amount of noise to the roughness okay so outputs we're actually going to have two outputs so first i'm going to have the output from this darken to this first output slot which is just a normal color it's going to give us a black and white basically a mask type texture to use on anything but we're also going to have a roughness output which is specifically used for the roughness input of of this guy right here if you want to use that so let's name things to make it nice and clean click on this output press in to bring us bring us back to this tab that i told you to get rid of and we're going to name stuff so we can leave the first one this color make the second one just name it roughness or rough and over here is all our inputs so this very first factor we want to give these names so we know what the heck they are first one is the noise mix it's going to add noise to the edge second one is roughness and the third one is amount so this is going to add the noise or and the noisy edge to the roughness which is this roughness output here the second one okay we're done we need we may need to set a few minimum and maximum values but i'm not going to take time to do that here except for this one because maximum you never want to go over maybe two or three there we go okay one thing i forgot to do was concerning the noise node down here we need to drag the black point up pretty high up to about 8 8.5 something like that you can type in the number there if you want to get real specific and also over here on the must grave let's make the detail pretty high or all the way up at 16 dimension at zero and lechinerity at 1.5 now look at that it's adding a good gritty noise which is what we want okay so let's tab out of the group and go back to our normal view so i found that this technique works best when you actually are using two shaders so click on this main bsdf and shift d to duplicate it down here now for the first one let's pretend that this is our uh our paint coat on whatever our prop is so let's give it a boring color maybe like a rusty you know orange red uh maybe a little bit darker right there and uh put your specular down your metallic to zero roughness all the way up because this is basically like a matte paint of a matte coating of paint right okay now the second one's gonna be the opposite keep your color at white and actually make it all the way up to pure white metallic all the way up specular all the way up and roughness all the way down so this is the metal underneath the paint which is going to be revealed when the edges get scratched and worn away right so we've got two shaders now we're going to mix them with a mix shader so shift a click on search type in mix mix shader and drop it right there so paint is on top metal is underneath and we're going to use the color output keep it simple and the factor so already you can see there's some of the shiny metal shining through now let's find an area of our model that has a very hard edges so this this area is pretty good right here there's some cubes and these cylinders are good so hit z and click on rendered and my light is really bright let me turn that down there we go all right so i don't have a really fast uh gaming a render computer so forgive me if you feel like donating one to me i will be more than happy so uh you can already see as it clears up the edges have a nice amount of noise to them which we can totally control and they are basically revealing the metal texture underneath which is reflective so they are going to reflect whatever is around us if you have a black environment they're going to reflect that if you have a bright light they're going to reflect that too so if i switch over to the dark side where the shadows are the edges are now going to be reflecting the blackness of my world or my environment probably can't see them too well right here but just a heads up that's what's going on so let's go back to our shader let's right click on our mesh for me it's right click for you out there you may have left click for select and let's uh zoom in a little closer and get to tweaking this thing so i found that the radius for you know dirty edges works best at 0.05 now that depends on the size of your mesh and things like that but let's turn it up to 0.1 just to make it a little bit more visible maybe 0.2 you can see it spreads it spreads from the sharp edge of the polygons or the edges you know in both directions around it now our noise mix if we put it at zero it's just the smooth you know uh edge from the bevel and the normal being you know whatever that math is doing is basically making just a gradient around the edge not very impressive but when you add that noise to it with our noise mix which remember is on darken mode it's darkening the smooth gradient edge with the musgrave texture so it's mixing them together with the mix rgb and that's what gives us a nice broken up pattern now play with this scale because depending on the size of your mesh you may want a really large scale or small scale of the noise if we do super small the noise is very large so you can only see little chunks of it here and there which is very random and not that great now if you increase the number to maybe 10 let me zoom in a little closer we can see it that's a little better and look at this on this cube the edges here are dark why is that because they are straight directions they are reflecting the blackness of the environment like i said earlier whereas these rounded edges on this pipe and on this little uh bolt thing as the cylinder they're reflecting the light which is right above the camera so that's why you get some darker and some white but that's good that's more realism right all right now uh so we've got radius scale noise mix these two things only apply to the roughness output which we're not using right now you can use that if you're using an individual shader like this and you want to you know play with the roughness and you can plug it in and you've got the the starting roughness and then the amount of noise you're adding to it but for this i like to use the two the two nodes set up and it really allows us to see things better you can also do some tricks to play with the you know intensity of the edges so i can maybe turn my noise mix to 0.5 so it's half smooth edge and half noise and i can even use a math node right in here on on basically the factor set it to multiply and maybe put it at two which will increase the values by two makes it a lot stronger of an edge and i'm going to switch to a different model because i'm not liking how some of these edges are turning out it's a great model fun to play with for sure but i'm going to show you on just some basic cubes so we can see a better representation of what this edge wear and tear is really looking like all right so we've got a uh interesting little qb shape here lots of hard edges even a bevel and a cylinder if you want to learn how to make stuff like this i have two or three different videos about hard surface modeling tricks and techniques and those will be really helpful if you want to learn to just make basic shapes like this alright so let's apply that material which was called edge tutorial switch to render view and here we go we've got the bright edges on top reflecting the light the dark edges down here are reflecting the darkness around them and that is because this edging that's created by the nodes of bevel and normal multiplied or whatever that math is together it's making a mask just like in photoshop black is masked out and white is opaque or masked in so what's going on is it's basically allowing us to see two different shaders depending on what those edges are doing and some of them are very they're very harshly reflective right now we can change that see i can actually see the cylinder over here reflected in this wall so let's turn the roughness down on that metal shader go back to shading over here just because i had roughness all the way down maybe point one let's put it at that might even render quicker we'll see so zoom in maybe add some noise back to break up the patterns here set the scale to five and our radius is really large which is not realistic if things are rubbing on edges the edge wear is going to be only on those edges so let's turn it back to 0.05 which gives a nice fine line i really like how that looks much more realistic now the smoother and edges the less of uh you know this edge effect is going to be applied so if you have a rounded edge with a whole bunch of subdivision it's probably not going to have any at all in fact let's test that right now so you see these edges right here are really bright you can see the fall off you can see the noise let's round the heck out of this i'm just going to grab the top and bottom line edges ctrl b for bevel i'm going to bring up the bevel pretty high and i'm going to add a whole bunch of faces get out of edit mode let's let it render there's a little bit of noise there but that's okay i'm fine with that small amount of noise but it's way less than before if you look at the face just above it that's still flat and you know 90 degree angles it's a it's a very stark contrast i really like how these nodes handle sharp edges it just seems contr it just seems more realistic to me so if you want this node group to stay with you forever and always be available to use and reuse and tweak and improve on in your default blender file what you want to do is click on the node group here edge detector and click on this little shield that's going to keep it so in case you delete the object that this material was on or this node group was on and you save and reopen it later this group is still going to be here even though it's not technically being used by anything so click on that shield and we're good we can delete this object go back to our normal view set your view to however you want it to be whenever you open blender and then go up to file defaults and save startup file and then click on that cool so it's done i'm going to close and reopen blender here we go just how i left it shift a let's make uh ico sphere for no apparent reason go to shading new material and this is how to add your group by the way i didn't say this earlier shift a and instead of clicking search or searching through these just go to group and we should have edge detector right there now all these dg ones are one that i've pretty much you know settled on and i've mostly finalized here's my edge finder i've got a scratcher a scratchy which uses image textures i wanted to add kind of a fine layer of dirt and noise cyberpunk windows and brushed lines for metal those will probably deserve their own videos later but here's our edge detector that we just made and everything is still there we can plug it in see that it's ready to go hope you guys enjoyed this video again if you haven't already please subscribe that helps me know that people out there like what i'm making are watching it and want to see more and if you have any suggestions for future videos or things you'd like to see me make or teach let me know in the comments below thanks so much for watching have a great week
Info
Channel: Daniel Grove Photo
Views: 56,415
Rating: undefined out of 5
Keywords: blender, procedural texture, procedural, substance painter, blender texture, materials, scifi, realism, 3d art, CGI, concept art
Id: yIxq_QAO7Og
Channel Id: undefined
Length: 19min 41sec (1181 seconds)
Published: Mon Jul 27 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.