How to Create Fog using Blender's Mist Pass (Tutorial)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in this blender tutorial i'm going to show you how to create this mist effect using the miss pass in blender's compositor now there's two different type of results that you can get while using this miss pass so the first one is this result right here and you can see that it's very foggy and the stuff in the background you can still see it but it's kind of just a silhouette and it gets like these different blue colors or whatever colors you want to use so that's the first effect i'll show you how to do that and then i'm also going to show you how to do this effect so this maybe is a little bit more realistic to the real world what this does is it kind of just makes everything fade out and fade out and fade out until it's fully faded out just into this fog you can see that like you can still see the house textures and everything whereas this one it's just a pure silhouette so i'll show you how to create both of these different results um personally for this scene i like this result right here but for some cases you may want to use this result instead and before we start i want to thank sketchfab for sponsoring this video sketchfab is a 3d model site where you can preview 3d models in your browser you can even view them on a phone tablet or in vr and ar they also have a huge 3d model store where you can purchase models and assets you can also apply to sell your own 3d models on the platform check out sketchfab with the links in the description alright so here we are in this swampy scene that i've created so there's a few different things that you do before we can actually use the mist in the compositor so the first thing that we need to do is we need to click right over here on the view layer properties and then right here on passes you're going to need to turn on mist then what you need to do is select your camera the camera in your scene and you're gonna need to go down to the camera settings and then right down here under the viewport display there's two things you need to turn on you need to turn on the limits and you can see when you turn on the limits it adds this line here and then you also need to turn on mist and when you do that you can see that it adds these two little dots here so one of the dots are right there and then the depth one is the little white dot right there all right so now that we've done that let's go over here and click on the world and then in the world settings you can see that there is now this missed pass so just open this up and you can see that there is a start and then there is a depth so if i just zoom out here you can see that the start when you change this it's going to change this little white dot right here and so what this is is this is where the mist is going to start so if you want the mist to not start for a while you could turn that up and then it won't start to like over here i want it to start right when you can see the scene so i'm going to start it like right here now when you move the start one it's also going to move the depth because you can see when i'm moving this one see this little white one right here when i move it if you look right over there you can see that it also moves the depth one as well so the depth one this is going to be how far the mist is going to go until it's 100 missed so um what i want to do is i want to be able to see the house i want to be able to see um the landscape here um if for some reason you didn't want to see like this landscape here you could just like have the depth one end like right here i want to have it like over here because i want to be able to see the entire scene and then just have it fade out kind of at the end there so the depth i'm just turning up that value and then again the start one is right here so it's going across the entire image and you can totally go back and change these values you're just gonna have to re-render your scene if you change the values alright so now i'm gonna render this out by just hitting f12 to render the scene and then after that we'll jump into blender's compositor and set this up all right so it finished rendering so this is what my scene looks like when i just rendered it out so now let's go over here to blender's compositing tab and we're going to click on use nodes right up there we're also going to turn on the backdrop so you can see the background and then it should already add a render layers and composite but if you don't see those you can press shift a and search for them and then add both of those nodes in now before we get too far into setting up the nodes i'm going to be using the node wrangler add-on so if you don't have that enabled you can go to edit and then go to preferences and then right down here you can go into add-ons and then just on the search here you can start typing in node and then just turn on the node wrangler add-on we'll be using that while we're setting up these nodes so i'm just going to close that now so now that the node wrangler is turned on what i can do is i can hold down the control and shift key and click on nodes and that's going to add the viewer node so you can see i just hold down control and shift and click and it's going to add this viewer node right here and you can see if i continue to click on the same node you can see that it's going to go down all of the outputs so you can see that because we turn on the miss there is this new one here called mist so if i just continue to hold down control and shift and click you can see there is our missed path so it's using that data that we gave it and it's making it black all the way here when it's closest to the camera and then as it slowly gets farther and farther out it's going to get lighter and lighter if you want to zoom in the background you can press alt to v to zoom in and then if you want to push the background out you can press v that'll make it smaller okay so it does look really cool and this is the data that we're going to use to create the mist so first let's press shift a and i'm going to search right here for the mix node i'm just going to drop the mix node right here behind the composite and then i can control shift and click on that to set the viewer to that as well so what i want to do is i want the image to go into the image and then i want to take this mist here and i want to put it into the factor on this missed output wherever it's white that's going to be using this image right here the bottom one which is this color and then wherever it's black that's going to be using the render layers so now we can do is we can click on this and change the color and that's going to change the mist so i like to have like a light blue color for this scene i think that looks pretty cool you could do whatever you want um whatever is best for the scene now you can also play around with this even more because right now you don't really have any way to change like the thickness of the mist so to do that i'm going to press shift a and i'm going to search for a color ramp and i'm just going to add the color ramp in and put it right here in the mist let me just bring this up to the top here so now if i hold down the ctrl and shift key and click on the color ramp we can preview what it's doing so you can see that as i drag this it's going to make everything more black and remember the black value means it's not going to have the mist and then the white value means it's going to have the miss so the whiter the image is the more mist there's going to be so if you want less mist you could turn that down if you want more mist you could actually turn this up and you can see now everything is starting to fade away it's getting harder and harder to actually see it like right there it's so misty you can't really see even that far ahead of you you can just see a few of those little plants and then as you drag this out the mist is going to get more and more subtle so if i just ctrl shift and click on the mix here now i can drag this around and you can see what it's doing so this is really cool and then also if you want there to be a little bit more mist close up what you can do is click on this and just turn the black value up because the lighter it is the more mist there's going to be so when it's all the way white it'll be all misty but then when it's more and more black it's going to be more and more the render layers so if you want things to be just a little bit more misty you could do that as well so there we go that is the first result um let's go ahead and create the other result which i actually like a little bit better so with this one we just faded it out to this color right here but for the second one what i'm gonna do is instead of just fading it out to one color i'm going to slowly fade it out to this missed image so if i just unplug these just make it a little bit simple unplug this so i want the image to go into the top one because we need to have the render layers and then this mist here i'm going to plug it into the second image so now you can see that it's going to mix together this image and this image now if you change the factor you can see that it's just evenly changing it between one image to the other so again we're going to have to use this missed value and plug this also into the factor so that we can use that missed depth to tell it how much mist there's going to be and there we go you can see that it's already starting to work but i want to play around with this kind of change the colors and then also change how much mist i want there to be so this isn't very hard to do the first thing that i'm going to do is change the color of the mist so i'm going to press shift a here and search for a color ramp and this one we want to drop this into this mist right here that's going into the bottom image and that way if i control shift and click on it you can see here it is so you can just play around with the colors again for this scene i like this like blue color it looks really cool i really like that look and then for the black here i don't want it to be fully black so i'm just going to make it like a dark blue so it just kind of starts as a dark blue and then slowly gets lighter and lighter so now i can control shift and click on the mix right here and you can see that's already looking pretty cool and then to change how much mist there's going to be i'm going to press shift a and i'm going to search for another color ramp and this one i'm going to drop it into the factor so the mist right here that's going into the factor drop it in there and i'll just kind of bring it up here and then if i control shift and click on this we can preview it if it's white it's going to be using the mist image and if it's black it's going to be using the original image from the render layers so if i just ctrl shift and click on the mix you can see that as i drag this up instead of the mist fading away it just turns into that missed image so this is where you get that really cool effect you can especially see it on the house right there it just turns into that silhouette there that foggy silhouette so i really like it it looks really cool and then again just like the first one if you click on the black value you can turn that up and it's going to make everything more and more foggy so even the stuff up close it's going to make more foggy and you can see that as i turn that up it's making the fog that's close up more and more indents so that's really it it looks pretty cool i'm going to show you a few different things though that you can do because let's say you want to add more colors in between the fog what you can do is you can just add more tabs in these different color ramps so first let's go down to this one and i'm going to click on the plus right here and i'm going to drag this all the way out and you can see that when i do that it's actually making it more and more contrasty so we can actually see that better and then you can change this color too so if you want to be a little bit more blue you can see that now kind of where the house is that's going to be this kind of blue color and then this is just going to be the very far background so you could do that if you wanted to and then the same thing for here so if you want to click on the plus again drag this one up close you can see that it's going to play around with the colors that are like right here kind of on that hill there i can just like drag this closer and closer you can see that as i drag it really close it really starts to affect the close-up fog and then again i can just change this color here so if i wanted to make it like a deeper blue and then i could also add another one add another one there maybe bring this one out put this one in between there you can see it's really kind of affecting the stuff close up so you can sort of think of this color ramp as these tabs that are really close they're going to be affecting the fog that's close up and then as it goes farther and farther back um this back one here it's going to be affecting the fog that's very far back alright so that looks pretty cool let's go ahead and play around with this one up here the second color ramp so you can see that as i drag this it gets more and more foggy but you can see that it kind of gets really sharp right here if you kind of draw it closer and closer so if you want to have like a smoother transition you could just add another one and then just kind of bring this closer bring it really really close you can see now it's kind of affecting this area and then again you could change the color so you're going to be very very subtle with this but if you just change it a little bit down or a little bit up you can see it's going to make it more and more foggy or less foggy and then again in the final result that i created um i just added like a d noise node just to kind of denoise that and then i also like added in some different things like a color or balance just to kind of play around with the colors and color correct the final image so as you can see this missed effect is really cool it's very easy to set up and it has some really cool results so thank you so much for watching this video i hope the tutorial was helpful and if you'd like to support what i do some really great places to do that are over on my gumroad and patreon i'd really appreciate the support but again thanks for watching and i will see you in a future video
Info
Channel: Ryan King Art
Views: 82,405
Rating: undefined out of 5
Keywords: Ryan King Art, Blender Tutorial, Blender, Ryan King, Tutorial, mist, fog, mist pass, compositor
Id: D6a6eA1hE8s
Channel Id: undefined
Length: 12min 31sec (751 seconds)
Published: Mon Apr 12 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.