MtoA 519 | Procedural Shading

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone and welcome back to the channel in today's video I will be showing you a new way of doing procedural shading and I will be using several different a I know it's combining it together to get a nice base color and I will be using that to kind of replicate this Deadpool 3d print on the left you can see it's the final result it's definitely more stylized than the result or than the reference but you can see the reference images are pretty nice you can see still the layering of the 3d print which I did not incorporate in the render but it's easy to do but I try to get the nice curvature stuff and the holes and you can see that we kind of have the the logo is liking being brighter on the on the edges and I kind of try to incorporate that and obviously I try to make a more interesting lighting setup which i think looks pretty pretty cool and I will be showing you the whole scene from scratch and I will be providing the model the lights HDR's the whole Maya file the reference images so if you want to get access to this stuff please follow me on patreon become a member and you have access to the source files and also feel free to follow me also on on Twitter and on Instagram and yes so on Instagram my tag is just my full name Instagram comm much NIDA and here you have always obviously some personal images but also if I post new stuff it will also go on here so you can see there is like the robot there's a Jurassic Park poster and all the stuff I did recently images whatever so you can see what's going on and obviously there is the slack channel which you go on light chatter but slack comm you can get the invite on light shader de and at the bottom is the sign-in button so when that page loads scroll all the way to the bottom and you get the slack group and this will give you access to this group there are a few like 500 members it's pretty active lots of people asking questions I'm trying to help most of the time but all the other people are helping as well which is nice it's it's a little growing community which is cool and then obviously patreon where you get access to the source files you can have exclusive you can have support from me if you want to have a quick hangout session with me and I can give you help on certain things you need all that stuff is happening so Instagram slack and patron that's the main things you can get in touch obviously Twitter as well but this is a typical thing we'll also post my stuff so you can follow me there as well anyway so let's jump in this is my scene I have prepared this is my pre tutorial test scenes this is kind of how it will look and we will be creating this whole thing from scratch so I will be just hitting ctrl and for a new scene completely empty and I will hit file save as so we on the right spot and we just call this em--to aid 518 training MA alrighty so this is saved and the first thing I like to do is create a few top-level groups so the one is lgt then we have geo what else we need camera I guess which is the main cam if you have more obviously makes sense to group them if you have just one it doesn't really make sense but I just I just like to keep it clean so this is my way of doing things geo is most of the time the sign in my case cameras I think I had it on black most of the time ok so then I create a new camera so let's just do view create from view this is my main right this drops into camera and that I like to have a focal length of 80 millimeters and okay so this is my basic setup and what I do now is I'll just drop in the geometry which you can find in the resource folder which when you want to follow along it's in the resource folder and you just drop in the Deadpool bust object and you should get it right here so and then obviously we need to rotate it by 90 on X I was hitting j2 snap so that's helpful I guess so that's the Geo it's pretty high details it's it's not perfect but it's it's very nice to just do a quick lighting test and it's obviously triangulated because it's a 3d print model but it's still it's still very cool so for the render I need to subdivide it once so I go directly let's first rename this and remove the namespaces so window general namespace edits select that guy and hit the lead merge of route so that's gone and just call this maybe that pool bust or whatever you want to know do and put it into geo geo group so it's nice and structured and then on the on the shape note after the Deadpool bus on the Arnold tab subdivision and able cat Clark and maybe two iterations most of the time one is enough if it's just highly decimated already so I didn't ctrl + s saving this guy and so the next step what I like to do is import or set up my my global lighting my environment light so in that case I would do lights sky dome light which is my Ian viel I drop it into light group call this maybe LG te and V it's it's up to you it's it's your life it's your scene this is just a convention I used to learn let's just drop in the studio HDR file in the scene and at the bottom if you enable the disable deck objects you should get a file note I hope okay it doesn't work if you drop it in the scene so in the hypershade let's just drop it there did I close it now I guess I did okay so I'm just opening up the location again and do we hear resources and I'll just drop it into the hypershade there we go so now we have a file now created and we will just connect this with my color slot in the dome light that's connected resolution depends on the input size so that's just to 248 which is the width of the image so I'm not sure if it's exactly that but that's something you can check and I like to always do like 3 samples depending on you a samples you should not go higher than 3 because it gets multiplied so let's just not just let's just stick with 2 for now and now we should have this one in here so that's the Asia which is also provided in the scene files and I would like to have the backdrop behind the character so I'll be just rotating it by I guess 90 it is so yeah so now it's kind of behind it and he gets the bounce light from the bottom and these two lights there I'm not sure how good they HDI's but I will be adding of lights anyways to that so viewport sky radius I'll just make this bigger so it's not interfering with my setup and then I need to change the clipping planes of the camera to see the background again so I just added another 0 so we see that thing back ok right so this would be the first step and if I hit render now let's see on old render ok so it's loading up at the bottom and this is what we get on the default scene set up it's running through perspective camera like so lets me let me just quickly update progressive on so it should update pretty quick check render settings it's on three I'll have a default preset do it on default so it's five one one we have read out of two on default and let's just bring a a samples down to two so now it's nice and snappy right that's what we like okay so before we go into lighting what I like to do is a sinus shader which is a favorite AI standard serve the shader and my default settings is fully white fully the weight on one and the colors of 0.18 which is a default gray at first it looks very dark but it's it's pretty neutral if you would put this grace via ball into sunlight it would be pretty bright so this is just a good reference point to set up your lights and then roughness for this guy is obviously it's too shiny for now so let's just do a roughness of 0.6 so we get almost like a lamb or shader again and yeah so this would be the basic lighting so now what I want to do is look through my main cam and show my resolution gate and just do a nice framing here so I'm not sure we can also change the resolution if we need to so instead of 1920 by 1080 we can do I guess that's just to 1500 and in height and width would be maybe that wasn't let's just see what we get now if I change my display and I do my over scan so that's what we got right now so I think we are still on a T we on a T so this actually fits pretty good thousand by 1500 now I'll just lock this guy so I'm clicking the button so I cannot translate the camera window anymore and now I'm switching back to your perspective and now we should be good if I update the scene we should get an update here as well and this is now my new random beaker that is now like taller than it is wide I like to actually move it move the window to the side instead so now I'm talking it on the side window locking it again so now I can actually just move it here and on the middle piece I can actually work with the hypershade as well so I'm not sure why I can't move this anymore this seems to be Lucknow weirdly enough but anyways let's just move this guy over and now this is what we got before okay before we will really play around with the shaders that just name this to Deadpool and this would be also I just I call it main like this okay so if I save the scene hit play and now we should be still able to do this yeah okay that's all good so I think the next step would be to play some lights and neutral shader environment so to do that I go to view panes and this is also weird so I think I need to change the near clip plane to one maybe or the bigger one there we go okay so creating lights so I go to Arnold tab lights area lights so this is area light one I drop it in my light group call this let's let's make a nice rim light from from from the right so let's just call it lgt on the school rim and now I have light shader it's a light control window okay which does not work right now it doesn't matter just a little bug but you can still view it so look through selected and we have the rim like so and now if I hit play that's actually still running so now all I got to do is change my exposure maybe to 15 and okay so it's definitely lighting the scene and it's definitely way too bright because I actually changed the env instead of the room light so let's try 15 again what's going on here okay that's rap date scene okay there we go it was just an update issue so now I can see on the left that the light is updating it's working pretty cool okay so now first we head over to perspective and you can see it's a really tiny light which is not realistic at all so to get the proper shadow softness make it like a real scale light would be like a softbox this is a small softbox and let's go a bit bigger like this maybe and obviously this is way too close to the character because if you would move it he would immediately walk out of the light so let's just pan it a bit differently go further back more we wanted to have a rim actually so oh that's just an able also save UI thread 3 so we have should have a faster feedback in the UI and now because it's further away we need to increase the energy of the light so let's go to 20 maybe and now you can see we get this nice hot rim and depending why you position it you get a different effect of the light itself but I think it's nice it's highlighting the eyes I want to call the the bone there I don't know the nose and that's the nice side LED red light which is pretty cool obviously you can play around with color I like ways to have the contrast of the light and cool and warm so you can use temperature if you want to and play around with the upper end which makes gives you a blue rim something like this and obviously you can just duplicate the light and let's call this one key and the key let's make the key warmer let's say five thousand Kelvin for the warm light maybe four or five and say key panels look through selected so now we're looking through the key light and let's just move this guy over to get a nice key direction of this guy which is also a fairly room lit but it's still more it gives it's the main light direction so that's why it's called key and in perspective so now you can see this is my setup so I've got my room here and the key there so if you want to have hard shadows from the key light instead of these nice and soft ones you need to scale the light source and depending if you have normalized on or off it's a different type of light so a thing of normalizes on the light intensity does not change based on the scale so you can see it keeps the same intensity but it changes the shadows softer so and if this is off and I just dial in my temperature and my exposure to some value and I would scale the light now you should see it's actually changing the light intensity also so that's something it's more artistic or easy to work with it normalizes on and you set a fixed exposure of 20 maybe or a bit more for the key light and then you can just scale the lights to adjust the shadow softness so now I'm just rendering this portion here and you can see if I make it really small you get these really hard shadows which gives a really nice key light direction and you can see if I make it bigger they get really soft and you get a more like a diffused light on here so hard shadows really soft shadows and I want to go for really hard shadows on this case so and now we can you can see it's pretty high which it's cool it's a nice fall-off still but you get the idea of really hard shadows right there so let's do it look through selected one more time and maybe just angling it from a bit more higher point so you get these nice cheekbone shadows as well just for more artistic looking and something like this so this would be now I guess the broad light setup we can dial in more let's just try 21 for exposure and I think this looks pretty cool already and if you want you can dial down the environment light a bit under exposure negative exposure to just reduce the fill and now you get a nice contrast image but I think that this went too far so let's just go on zero I keep it on default so this would be now the light setup for this guy and you can see now even though we initially we had a pretty dark shade now it looks pretty good right in there in a nice light and it's a very natural fall off so let's save this guy can just save this image as well and I think this was my test I'll delete this guy okay so this is our starting point for lighting for shading and for shedding let's just change the resolution to 50% to get even faster feedback on the shader changes so now I'm changing my UI to hyper shade selecting that pool and right click to get just a shader layout alrighty so the first thing what I want to do I want to have it a metal object so you can see the reference images it looks pretty metallic so what I want to do at first has changed the mode to be a metallic shader right so we first change the shader to metalness to 1 and now we have a metal shader right so it's fully metal it has a base color of this dark gray you can see it already it changed and the render to don't have any diffuse component anymore so that's what we want so before we really go to the final render what I want to do to you to illustrate what we did here is we need several things we need occlusion because you can see that in the ridges it's really dark and you will have curvature so on the edges you can see that there is a brighter color so all these things we need to consider and we will be doing this right now so I'm just minimizing okay so the first thing what I always like to do is create a AI occlusion I am an occlusion shader which is this guy and I already know I want to use curvature so I'll create an AI curvature node and I also know I want to use a facing ratio node so these three nodes I will be using and then I will be stacking them in several layers to make it very interesting so this approach will a bit different I will be using this all of these guys on the left as mask inputs for a colour correct node and so I will create the AI color correct which is my my input color and this will go into my base color of my main shader so currently the input is black but I want to have already at in the beginning I want to set up some some slight variations and you can see that there is like it's it's not fully uniform there is color differentiation and somehow the the hotkey for the minimize doesn't work here but anyway so I want to create a simple noise ai noise like this which goes into the input of my AI color correct and I wanna enable isolate selected so I can only see what my selected node looks like and you can see the noise is way too small so I'm changing the scale maybe to 0.05 0.05 0.05 so now I get a pretty large scale pattern I want to add a little bit of distortion just to get more interesting results and yeah so this should be all I want to do and then I will just because it's a metal shader the colors here are representing how reflective it is so a fully white one is almost like a chrome shader and the darker we get it's more like dielectric so we want to have an interesting range maybe something like this as my base color so the the brightest color is point 3 which is fine in the dark at this point let's just go to 0.14 the darkest color and this will be my input for my metal so now even though it looks similar there is definitely a color variation now appearing so you can see now what's going on there so let's just call this AI noise and this would be my base and this would be my let's just say a CC base as well and from here on we do color Corrections on this input color so if I isolate this this is my base color and then we will be using these three guys on the left to create interesting breakups on the base colors so first of all let's connect the immuno occlusion to an AI arrange node which is just a min max so you can control the values a bit better and the out red is just a float color you can use green or blue because it's all grayscale and this connects into the mask of the base color so if I want to visualize the occlusion I can just click on it and this is now what happens so this is what the occlusion looks like and if I woops and if i scale this window now down by a bit which I can't do why not when no let's see mode resize no I just wanted to scale it actually let's see if there's a way to do this minimize lock to window I don't think there is a way to because I made it fullscreen I can't really anyways let's just minimize it I wanted to have it as an overlay maybe I should close it save it desktop and try it again sorry for this saving scene let's try to reopen this guy no I don't think it worked it's still fullscreen mmm anyway it's never mind so occlusion so you can change the distance here so we want to have it just maybe five units from the shading point to final cluding objects or ten units and then you can play around with a spread to get more contrast in this guy but we want to have it pretty large because it should go in all the ridges so something like this and then I want to arrange it so I can actually control it a bit better so if I want to make a dark I just change the input min so now I can see we get a lot more contrast than this and obviously this might be a bit too much but this is just a mask and this will drive in the end the the color corrector node so let's just see what this HAP this does so the occlusion goes into my base like this and now if I would just because I want to make it dark I can just multiply it based on the the mask input so if I reduce the multiply color you can see what's going on here so it's definitely doing the opposite so I want to switch these guys out so white is black and black is white so I get the inverse and then let's see what this does and now you can see I can just color correct or darken the areas I need and this is just a color corrector so it's very handy and you can lock this lock the render know to the color corrector if you hit the little lock icon in the bottom and then you can still play around with the ranges and see what results you get so this is interesting so this would be now mime metal reflective colors so you can see it's really talking the ridges where there is some dirt occlusion or something like that I still think my base is a bit too dark but we just keep it for now like it is and now we just jump to the curvature so I'll create a range again it's just it's just a habit for me to be able to control it more precise you don't need to do it you can just use it directly but it's it's for me more control so I'm duplicating control the CC with a colour correct node and the out color of the base one goes into the input of the curvature one like this and then the out color of this goes into the base so now we should have still the same result but because we don't have a mask input so if I use a red Channel go into a mask and check the curvature which is looking like this for now let's just play around of the radius to make the curvature work better so now you can see we get these nice round edges of of the curvature and you can play around of the bias you can play around with all these parameters to get an interesting result which you want to get so multiple our just multiplies the values obviously let's just multiply and reduce the radius so we get a thinner line is that I'm working anymore there we go occasionally hitting safe is always a good thing to do okay so this is now my mask slot this goes into the range I can now clamp those values a bit to get more refined lines and smooth stuff is like a clamp value so it doesn't go higher than one all right let's just try this guy okay so this is my mass this goes into the curvature and now you can see because we had duplicated we also decrease we have a dark multiplier so if you want to make lighter edges you need to hit add so now I'm adding color to this and you can see now this would be my base color and if I if you check the file out but now you can see that he has now these nice brighter edges which is very nice and exactly what we were going for and the interesting thing for the curvature is you can have the convex which is the the round shape and you can have a cone Cave which is the inverse and the concave in most cases is where you would collect dirt so what I do like to do is I just duplicate the curvature node and switch the mode to concave and duplicate the color correct again hope these guys up connect here and this time this one goes we don't have a range now we don't maybe need one and connect this here so this is now the inverse and instead of making it brighter we want to make it darker this section so now you can see that we get these darker outlines right here and there which is interesting and the facing ratio is similar to the Maya one which is a sampler info and from there you can extract the facing ratio this one is directly outputting the values you need right so let's connect this to arrange the out value this one outputs only floats on what you would need to do is I'm not sure if there's a flow to RGB actually flow charge EB there's actually one so I think I'm not sure if I do this oh it's kind of the same I guess if I would connect it they are there it doesn't matter so let's just connect this up and whoops smaller node move it over duplicate this obviously you would you should be renaming this so this would be I guess coverage convex and this would be facing so I'm just stacking these guys up together this one goes here and then the odd red goes into the mask all right so now let's see what this actually looks like so this is the typical facing ratio note so what I want to do now is I want to darken the edges which are almost 90 degrees to the camera so if I play around with the of the gain and the by as you can see what this does so if I have a let's see okay so that's the bias and if I play around if the gain you can see what's happening here and I just want to get really the outer edge so what you can do is invert this guy make it maybe linear so it's easier to control play around to bias to just get the outer edge let's see if I can actually get it to work there we go so this is what I wanted to do so now we only capture the 90 degrees surfaces faces of that geometry so I'm assured of the linear whatever it really does I'm not entirely sure but you can see you get nicer control of your edges and you can have a soft to fall off which is interesting so I think I will be going with something like this and we can then control it a bit more clamping those values if you want to have more control and anyways this goes into the colour correct node again and now because we have a multiplier already this is the default one so now I'm multiplying with black and we get these nice darker edges which is very interesting and let's see the final result for now and you can see it's very interesting so if I wouldn't do that all these setups and I would connect it directly with my base colour instead so this is how it would look like you wouldn't get the nice curvature on the edges and all that stuff so let's reconnect this guy to get this nice detail and if you want to add these lines which I had and the reference image which I cannot move over anymore which is on my second screen unfortunately let's see anyways oh maybe I can right-click here no okay nevermind so the next thing is what I want to do I want to add these lines and because I don't have a TVs you vide I want to do these lines using a projection so I'll just create a ramp shader based on the projection and if you stop this for now and switch over to the view panes you should get a place 3d node and it's fairly small in the origin so I'm just scaling it up for now so the default projection is a planar one which is exactly what we want we want to project a one you can see I'm actually translating the key light which sucks so let's see if we come back go back where we had it I think we had it like this hopefully okay back to perspective so this is now my projection plane our texture 3d node and this is projecting the ramp onto the object so back to the hypershade we have the projection it goes in here place 2d goes there and this projection image is what we want to project on so if I just choose out color for now and just plug it into my base and I initiate the render again hitting play you can see now what's happening so the projected image is being applied and it's looking like this so now I want to get this repetitive pattern and to do that I just need to make it white in the center black on the outside maybe scale these two guys a bit more down add another white here so we have a constant colorless Center and this is now the pattern and obviously you would need to make it a lot smaller so we go into place 2d and maybe try 20 repeats on this and you can see now you get these fine lines of something and you can play around with the noise and the to denote so you can add some variation of noise patterns just to break out these lines so this is something which might work for you obviously it's too much but this will be a mask as well so we will just be moving these guys over first duplicate the facing ratio guy call this one maybe lines connect these two and the out red goes into mask and then color goes into base color so if you look through the lines no now you can see that we are multiplying so that's my default and if I just want to make it maybe brighter on these lines we can do that so now you get these nice streaky patterns here just because of we had this projection right so the final result looks like this now it's really subtle but you can definitely see the effect happening and so next step would be to maybe add some breakup inspect so you can just do an AI noise for this something really simple but you can make it more you can stack different noises together add really interesting results but this is now just showing you how you can do it pretty quick so looking through you can see it's a small pattern we want a large scale that's try point one like this we'd add some detail we add some distortion start updating it's just to update full scene it's safe so now this is my distorted pattern we want we don't want it to be really shiny so would you like pretty rough as a base 4.2 maybe and the most rough thing would be maybe 0.6 like this so let's see what this looks like okay so now you can see it's it's showing you but it also has these rougher spots like this and you can also use this as an is a trap map you just plug this the same thing into N is a sharpie and you get also nicer light response when it goes over the surface something you might consider so this is that let's just try to go in 100% so it's not scaled down one-to-one a bit more detail in this guy we can still see we need to amp up the render settings but this is working so far pretty cool so what I said about an easel choppy you can't plug in a map here to get interesting results as well so it's kind of like a brushed metal which you can utilize so let's plug in a map in here let's just duplicate the noise and plug it into anisotropy so middle Mouse drag then you get this dialog so I would color red goes into spec anisotropy and the default value is what we just said is 0.6 and 0.2 0.6 so we can go pretty high to almost 1 and maybe a bit lower so let's see what we get so this is now driven by a noise pattern and if we play around with the rotation you can see very interesting things so if it would move into light and out of light you can see that this effect would be appearing on the surface and you can also control rotation with a map as well so that's up to you so what else we can try to add some bump with the with these lines so let's do that so let's create a bump to denote the projection image is the value so we connect the red to the bump value and the out normal goes into the normal camera so now we've got the bump on it obviously too strong so play around with the value point 1 maybe you can still see its I would saying for my taste it's too strong so let's have it one more time even that is still too strong so I half again it's getting there so let's show a point 1 I think this looks reasonable you can see the nice effect on it let's see what we get here and I think it works pretty good so now you this is kind of all I wanted to show which is the stacking of color-correct notes and driving them of mass so this is a very convenient and easy way to set it up and you can now play around you add dust layers or all that fancy stuff but this is now a pretty good result you illustrate how to set it up it looks like a bronze bust or something so this is my original just default shader this is with the metal and all these procedurals so I'm saving this one as well I just wanted just now for a quick thing play around with thin-film it's also very interesting and it gets gives you like this oily coat so let's just render this part here and enable it the thickness so you can see what's going on there and you can drive the thickness with a map and let's try to do that so I'll just create a noise again and you before we plug it in you can see I have a value of 300 now we get this nice purplish stuff right so keep that value in mind so we connect the noise to the thickness out color red goes into thin film thickness let's check isolate selected so we get an interesting pattern so this is again too small so let's primary point one let's add some octaves for detail and really distort it quite a bit to get these weird circular patterns yeah that's cool and then we had a value of 300 right so let's try maybe value 300 and vellieux 800 and let's see the results you can see now there's definitely some color on this guy and you can see it looks like an oily something it might be definitely too strong so we just reduced these numbers a bit 70 maybe let's reduce it more and you can see you get different patterns so that's something you can play around with and even if you want to change the the pattern itself you can just scale it up change the distortion amounts get something interesting here let's try so 800 again I like that pretty much so it's more like an oily or like a hot whatever it is it's interesting I guess and then we can add a code if we want to do that on top of this so my base is a pretty rough image I guess and if you feel free just add a coat on top you can play around with the IOR make it more shiny more like a thicker coat layer on top of this guy right so that's on its heart you see because we have the base on as well but if you would create a v's you can just isolate the code let's just do that and you can see what's going on so render settings a UVs and let's just do coat let's just do speck just for the fun of it let's check the code so this would be my code layer which is very shiny and good-looking and then my default spec is just this guy and they get blended together and the beauty so you get these nice hot pings on this guy it's a different result than we had in the introduction but it's also very interesting and you can see how easy you can just create this interesting metal looking effect just with these simple procedural noises and obviously if you want to make a more interesting render what I like to do is set up depth of field and to do that I have a little helper script which does the hard work for you to do so you select your camera you select your object you go to a light shader help her focus rake and yeah it creates you this focal point and with that you can actually easy control your distance and your yeah your depth of field so I will show you how it works because depending on scene scale your aperture might be too low so you might need to increase this guy you can see now the focal point is somewhere in his arm but I want to move it a bit up on his I'd say on his nose that's an able wireframe like this okay so now I think it should be updating properly so now the focal point is kind of in his face area you can see the fall-off is very strong so we need to decrease the aperture let's try this so this is out of focus check the beauty change your mode should be shaded and now his arm should be but better out of focus I think it's already too much so let's try maybe two yeah this might just work yeah so this sums up the tutorial and I hope you you liked it and you got a few new tricks in your toolbox to do new interesting shaders let's just render this for good and again all this stuff you can get access to on my patreon page you get yeah you get the access to so as far as to get the Maya file you get the environment light you get the mesh final renders all that stuff so yeah give me a thumbs up if you like this video and obviously like you support I really appreciate your input on all the stuff I'm doing and yeah I'll see you in the next tutorial thanks for tuning in bye
Info
Channel: Arvid Schneider
Views: 19,123
Rating: undefined out of 5
Keywords: maya, autodesk, arnold, training, tutorial, shading, lighting, rendering, lookdev, vfx, arvid, schneider, material, procedural, mtoa
Id: -w7WoCnYjSc
Channel Id: undefined
Length: 46min 8sec (2768 seconds)
Published: Sat Jun 02 2018
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.