Create Simple Explosion VFX in Blender Mantaflow - Iridesium

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey what's up guys Joel Adams with iridescent and I am back with another pretty cool tutorial today we're going to be taking a look at creating an explosion inside blenders new smoke simulator creating explosions in mantle flow is kind of tricky because mint flow is not that fast hopefully in the future we can speed up its performance maybe even make it real time so anyway let's jump right in and get started I'm going to start by hitting a to select everything and then delete everything because it's all useless now we're gonna add in a floor plane so add in a plane scale it up to maybe eight go to your physics tab and choose collision I'm gonna turn this particle damping and friction up then set the randomize up a little bit as well then I'm gonna add in our first emitter that is going to be an eco sphere scale it down and set it above the floor playing something like that then go over to the particle settings tab and add a new particle system if you hit spacebar you're gonna see some particles jetting out that's fun I'm gonna turn our end frame here to 50 so we don't have to wait very long for the explosion to refresh set the start frame on the particles to 10 and the end frame to I don't know maybe 15 yep something like that turn the life down to maybe 7 then go under velocity turn the normal up to I'm gonna say six and the randomize up to six as well yeah that's pretty decent like that's already looking nice so I'm gonna turn the lifetime down again to five and I'm gonna call this our first emitter if you look at an explosion you're gonna notice that there's not just one big blast right at the beginning there's actually several blasts so there's like a main explosion and then there's a couple smaller explosions inside that one so let's go shift s cursor to selected I'm going to add in a scale it down to be roughly the size of this sphere tab into edit mode and move it up so it's right above the sphere you can use R to rotate or you can use these this is scale tool to actually make your object bigger rotate tool to rotate it translate tool in case your cube is in Latin then what we're gonna do is we're gonna rotate this with our off to the side I'm gonna add a new particle system and then I'm going to turn the normal velocity up so it's just jetting out actually let's hit alt R to clear the rotation so we can see it jetting up into the sky I'm gonna set this to six just like the sphere was and we'll set the randomize to six as well see how that works okay that's a little too much let's try five and then seven here okay let's try four for the randomize now I'm going to set the start keyframe to 10 and the end keyframe to 14 yeah that's that's not bad that's pretty decent let's turn the lifetime down to five now I'm gonna turn this randomize down yet again to three and this up to maybe eat so now we've got a very basic emitter I'm gonna rotate this off to the side so it's sort of jetting down at the ground and if we look from the top view you can see our explosion is not shaped perfectly spherical but it actually has this thing jetting off the side now what you can do is duplicate this and rotate it around on the z-axis to make our explosion again more kind of oval shaped so now with these emitters we can finally add in the smoke before you add in the smoke go ahead and save your file control s and save it somewhere on your hard drive once you've got it saved you can grab your middle explosion emitter which is this little sphere and go object quick effects and quick smoke I'm going to move this up on the z-axis and hit period to scale it around the 3d cursor scale it up and I'll actually shift C to Center your 3d cursor again it was on the sphere so it was scaling weird something like that and then on the z axis now you want to keep in mind that your explosion is going to behave differently according to its scale so you want to make sure it's real-world scale so if I add in a cube and we hit n to open up this panel right here you're gonna see that the dimensions are two meters by 2 meters by 2 meters and I think that's pretty decent that's like a medium sized explosion it's not enormous and it's not a grenade so let's just leave it like that so I'm gonna scale this down on the z axis just a tiny bit and then let's go to its settings if you go to the physics tab you're gonna see the fluid settings here so on this big cube a fluid type has been added under the physics you can see it's set to domain under the settings the domain type is set to gas because we're doing a gas simulation a liquid simulation this is the resolution divisions of the gas so how high or low quality the simulation will be you've got time scale don't touch that you've got CFL number that's kind of a complicated value also do not touch that and then you've got your data baked right here so you can make your cube baked I'm not gonna bake it yet let's change a couple things first under your smoke settings you've got a vorticity value right here set that to 0.1 0.1 is pretty high and I would not recommend going over point two because you can get some crazy stuff with vorticity then you've got adaptive domain I'm gonna turn this on adaptive domain is a very dangerous setting you can get a lot of clipping which will really screw up your simulation either turn it off completely if you're getting clipping or just leave it on and then carefully adjust your shader to not show the clipping then you've got noise right here I'll show you how to use noise later but we're not gonna use it at the moment and last you've got your cache settings I'm gonna set our end frame to a hundred usually I use 150 to 200 so I can get an idea of what the simulation is going to be but for this tutorial I'm just gonna leave it at 100 I'm going to go ahead and set the cache directory the simulation files are going to be really really big depending on how high Ellucian your explosion is so just make sure that when you're done rendering your explosion when they're done with the explosion completely that you delete your cache folder so if I go ahead and hit bake on this it's going to bake pretty quick and I can hit escape and if we play this back you can see a tiny little wisp of smoke comes up and then that's it and it's over that's because there are more settings to the simulation go ahead and click free right here to free that bake it's going to delete all the old files and give you your domain back now select your sphere and you can see that there's a whole bunch more settings it's set to flow it's set to smoke I'm gonna set it to fire and smoke just in case then this in flow is correct you don't want it to be set to geometry then you've got some initial temperature density fuel leave all that the way it is what you're gonna want to do is go under flow source choose mesh particles and choose your particle system that way instead of being emitted from the actual geometry here it's gonna be emitted from the particles which is what you want and then you're gonna want to choose initial velocity so that the smoke is really jetted out with the particles so I'm gonna do the same thing for these planes choose fluid flow fire and smoke choose inflow so it's not just one initial geometry it's just constantly constantly breaking the wind then go under here and choose particles particle settings and initial velocity now instead of doing all this to the other plane I'm just gonna delete the other plane select this one duplicate it and rotate it around so now I've got three emitters and a domain let's go ahead and bake this and see if it's any better you can see that it's taking a lot longer to bake however if you are curious to how your explosion looks just hit escape any time that will pause the simulation you can then hit resume to finish the simulation whatever I'm gonna hit escape and look at it so the first thing you'll notice is that the smoke is dark gray and it's hard to see against the background if I add in a light sunlamp rotate this put it off to the side I'll choose period to move back to the medium point and I resume you're gonna notice the next few frames are actually baked with lighting at kind of ridiculous looking lighting and it's easier to see so let's hit free bake go into viewport display and choose color mapping that's how I like to view my explosions now if you bake this again you're not really able to see the fire anymore but you can see a lot clearer picture of the actual explosion you can see the density which is really nice now because of the noise we added we're getting some nice little bubbles in here and it's overall looking really cool it's pretty big and you can see that it's clipping right here on the edge of the domain so let's free this I'm gonna scale up in on the Y a little bit it doesn't need that much space on the y axis but it needs more on the X and a little more on the Z make sure you choose a period 3d cursor to scale on the Z so it can rise up in the air a little further now we're gonna turn up the resolution you can see this tiny cube in the corner this tiny cube is telling you what the resolution of your smoke is so this is like one 3d pixel it's one voxel and this whole cube is filled with them so if we set this to 65 you'll notice it shrink a tiny bit you don't want to set it to 65 you want to set it to something that is going to be a binary multiple so for now I'm going to use 128 resolution divisions so the last thing we're gonna want to do is set this floor plane as part of the smoke simulation however you can't just set a plane as part of the simulation it has to be a so instead of setting this floor plane we're gonna shift a mesh add in a cube and scale it one z axis something like that s shift Z and make it about the same size as the plane maybe a little smaller so we can actually still select our plane and scale it on the y axis choose fluid none and effector you can also set this to be a flow object just set it to geometry and then set the initial temperature to be like minus 3 and it will act as dust on the ground that can give a really cool effect I've seen some other people do it it's it's really nice however for now I'm just gonna use an effector and set that as collision so I think we're ready to do a final bake let's um let's just bake this a couple frames and see how it's looking all right so I just paused the bake and I'm gonna go shift left arrow to move to the first frame and spacebar to play and that looks pretty cool now we're not really getting enough noise I might turn the noise up however as you turn the resolution up your noise is also going to kind of increase so you want to be really careful with that if you want more bubbles and smaller ones then you just add more particles and turn their their size down so I'm gonna do that I'm gonna select our sphere here and turn this up to maybe 2000 particles and then go and turn the flow source down to maybe point yeah seven we'll try that I hope and I'm gonna do a final bake maybe it'll be good maybe it won't if I was making a explosion for a film for instance a short film I would not do the final bake yet I would continue tweaking it until it is exactly how I want it so anyways go ahead and bake this at 192 and I will come back when it is completely done all right so I just finished that bake and if I scroll back to the first frame and play this you can see that there is a small problem and that is that I seem to have turned the particles instead of from one thousand to two thousand I actually turned them from one thousand to two hundred which wasn't what I was planning but it actually doesn't look that bad it gives the explosion a very unique look it's very very wide now and you can see that the main blast in the middle is got more particles like it's got arms basically I am gonna rebake it with 2,000 particles but I'm not going to do it yet we're gonna work on the material first now after I baked the initial simulation at 192 resolution divisions I actually went ahead checked noise and just baked it at the default settings so we can get some extra detail in there so once you've gone ahead and baked that let's do the lighting so I'm gonna I'm gonna scrub to maybe frame 50 that's a pretty decent frame and I'm gonna go up here add in a camera control alt numpad zero and then I'm gonna go maybe move it out and then controlled B select just the camera that's gonna make it so the in cycles nothing outside of the camera view is rendered we are going to be using cycles to create the materials for this just because cycles is nicer choose rendered and don't switch this to the shader editor yet go over here switch to cycles if you have a GPU use your GPU and then I'm going to set the world to I'll leave it at grey I'll go over here and choose transparency then I'm gonna grab the Sun lamp rotate this I'm gonna have this coming in from the right turn it up to 12 duplicate it rotate it so that it's coming in from kind of the back left and set it to bluish leave it at 10 go to the the front view and rotate it so it's at more of an angle this plane right here is also not going to be rendered give that new material set it to diffuse and then give it a dark brown so it's kind of the color of the ground then go over here visibility and just turn off the camera so it can't be seen by the camera but it it's still calculated now this cube right here can be you can uncheck everything and I think we're set up so select your domain again and switch this to the shader editor so the first thing I'm going to do is turn up the density and yeah that doesn't look terrible I'm actually going to delete this and add in an input volume info plug the density in right here add in a converter color amp move this forward just a tiny bit then add in a converter math node set it to multiply turn that up 75 is good I'm also going to go to our render settings under light paths turn volume bounces up to 2 and then go under volumes and set the step size down to point 2 so that renders faster it's not as accurate but that's ok we just want to render fast at the moment explosions are not going to have this perfectly white look so you're gonna turn it down dark and then maybe give it a tiny bit of color like it's kicked up some of the dirt you can actually use the density to control the color if you want to I'm gonna unplug that though for now and just leave it all one color this is a simple explosion on an advanced one then let's go and add in an input and attribute node and we're gonna type in heat sometimes I use the density to control the fire but for now we're just gonna use the heat plug the color right here into the emission color I'm going to choose converter color app and then we're gonna use the strength value right here on our node turn that up and I'm gonna turn this contrast up add a new color ramp right here make it a a nice orange color something like that I'm gonna change this to be yellow and then set its value to maybe 3 instead of using white we're just gonna use yellow set 2 of a high value of to get something like that and that and that looks pretty cool I mean that's I'm gonna also trim the saturation up something like that and then the density here up to a hundred you can also use the density one hand typing yeah and you can see that's given an even different look which isn't bad again it looks okay now you'll notice the explosion looks a little weird like it's not fully rendered or something and then there's like these lines in it that's because we set this step size so high if I set it to point zero five it's gonna render a lot slower but it's gonna look nicer crank this up yeah and then if I turn the saturation on myself and the saturation on this up now one other thing you can do which I do quite a lot is set this colorant that's controlling the density to constant and this will give you a truly dense explosion you're gonna have to set this down there maybe ten let's try let's try 20 yeah that's okay and then you're gonna need to set this down even further the denser it is the further this is gonna have to be set down now it definitely has problems and one of the main problems is that it's super low resolution for a very low resolution simulation now this is looking pretty damn good I think it would be worth rendering it out in any case I'm going to save this version of the material I'm gonna render this out but I want to see what else we can do with this material so I'm just gonna duplicate it the whole thing and move it up here and then click on this now will allow us to get control over the material so if I turn the emission all the way off let's look at just the smoke this actually looks really nice like I don't know a lot of people love the big orange fiery explosions which whatever I like the power of the explosions that are just that are just dust that have obviously just kicked up tons of dust there's not a whole lot of detail in this explosion which kind of sucks one thing that you want to make sure of is that your material down here is set not at linear it's set to cubic it will make your explosion look slightly less detailed but it will get rid of some some weird artifacts before I do a final render I'm going to select this so it's rendering our this material that we set up I'm gonna go over here and I'm gonna do a render at 20% and I'll turn this 2.1 so it renders nice and fast and I'll turn the bounces off I'm doing this so that I can get an idea of the actual flow of the simulation like how how its movement is going to look in the end I don't want to render for like two days straight a animation just to find out that it's actually not moving right it's got some weird motion so make sure the whole thing is in camera of course I'm going to choose period 3d cursor double tap are all right so I'm gonna render this out and then once it's done rendering out if it's good I'm gonna do a final render and once the final render is done I'm going to I'm going to bake it at higher resolution 256 is about the minimum I would recommend baking at so I'm going to use 256 or 320 or 420 if I'm feeling really excited about this simulation and then I'm gonna call it done so here's what I got from that bake and you can see it looks pretty decent it's pretty low resolution and there's some weird glitching going on once I turned up the resolution and actually added 2000 particles to that medium blast I got this which looks pretty nice and then tweaking the material a tiny bit I got this one which I actually really like even though it's a little low resolution still I actually turned the resolution up to 512 and got this but there's some clipping going on at the right which is kind of annoying so I was unable to use that then after changing the material and doing a little more tweaking I got this and this is my favorite result it's not super high resolution but it does look pretty good and it worked very nicely in some other rendered footage that I had very nice unique feel it's kind of a tan color so it looks like there's dirt getting kicked up and there's a nice balance between fire and smoke now keep in mind that your material is more than half of what makes a good explosion just from one simulation you can get a ton of different looks just by messing around with the material so keep that in mind and play around with it try to get familiar with making fancy materials because that can really be a strength when making simulations another thing that manta Flo is really good at is fire you have to go pretty high resolution to get some good results but it can make almost completely photorealistic results just with manta flow so anyways that's basically it the only downside that I find to Manta flow is that it's really slow it's kind of too slow but hopefully in the future Manta flow can get sped up a bit and blender can be I don't know on par at least with some of the simulation software out there anyway so that's all I've got for you guys today thank you for watching and I will see you next time this is iridescent
Info
Channel: Iridesium
Views: 800,453
Rating: undefined out of 5
Keywords: Iridesium, explosion, blender, vfx, cg, nuke, blast, simulation, mantaflow, fluid, cinematic, cinema, 3d, blender 3d, grenade, tutorial, fire, smoke, volcano, i see you reading the tags
Id: 29yfS-icS3M
Channel Id: undefined
Length: 23min 0sec (1380 seconds)
Published: Wed May 20 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.