Realflow For C4D: The Rigid Deformer

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] hey guys it's Sam for digital meat and in this realflow for cinema 4d tutorial we're going to be looking at the rigid de forma and how we can have objects interact with our fluid okay so I'm just going to set up a simple demonstration first of all so I'm going to create a cube make it a bit flatter I'll zoom in a little bit and let's give this cube a Collider tag that I'll do for now and I'm just going to create a sphere shrink it down a little bit there we go and I'm going to create a go into realflow go down to deformers and we're going to choose rigid it'll create our tree and create this rigid object let's just put our display onto that for the moment and what you want to do is take this rigid body out of here and put it in to our sphere now if I press play not a lot is going to happen in fact let's grab our box and rotate it slightly just so sphere slides off and that's because the reason that nothing's happening is because we've got no gravity in the scene so let's go up to realflow demons and add a gravity demon and then press play and you'll see that the sphere Falls but it doesn't interact with our cube and that's because if you go to the collider on the cube there's no links to anything and it's because we created this first and then the scene tree so it's asking for a real flow scene so let's drag that in and it's asking for a link to fluids and whatnot there is no fluid in there at the moment so that's not gonna help yes you know if we've got gravity but there's still no interaction between these objects and that's because if we look at our Collider here our rigidbody has gotta be seen as a link so they can interact so if I press play now right we've got some interaction between our sphere and this ball now you're probably thinking well this is kind of pretty pointless really because I could do all of that with them cinema for DS built-in tags but if there was some fluid in this scene cinema for DS dynamic tags are gonna allow allow interaction between this sphere or the colliders on this box to interact with fluids and so that's kind of the point of this some you know this kind of SAP you can actually have fluids in there interacting as well but we're gonna be dealing with the rigid body so I'm gonna close this seed and I've already got a scene set up so let's go to this clothes don't want to save it so that'll close this right okay so I've got a scene and it's already kind of set up I've covered a lot of this in previous tutorials so if you want to learn about collision tags and the demons and all that kind of thing you can check it out on my website digital meat UK and you can fill up the tutorials via realflow and all those will be there you can also find it on a playlist on my youtube channel as digital meat so anyway let me just explain my scene setup I've got a scene tree here I've got a gravity in there like we did a minute ago I've got a kill volume which is basically any particles going outside of this box will get killed off and I've covered that in previous tutorials to know I'll go to some lights to light the scene and my scene objects which is basically the room itself a fill object which is here that I've hidden and the container and the containers got a couple of them tags on here it's got the collider tag and it's got the volume tag as I said before I've actually covered these tags in previous tutorials so go look at them if you're not familiar but for now this is you know this is about the rigid deformer okay so first things first let's get into this so I'm going to just turn off my grid because that's kind of annoying this fell object we need to fill it up with a fluid so we're gonna need an emitter and if we look we've got a filler mail already in the scene so I just got rid of that actually just saw it back to the beginning here to real flow I met up Phil you are Phil emitter in the scene it's linked to our fluid automatically by it's gonna need to know what object it's going to fill so we've got this fill object which is basically this box here I'm gonna grab that and drag this into this field I'm also going to turn this fill object off at least not being visible for rendering in the viewport and let's go look our fluid it's got a resolution of 15 it could be less than that if you wanted it to be yes sir let's make it 10 just so it runs a little bit better and we'll hit play oh okay another thing that I want to do as well it go to my scene and actually in the in the fluids let me just go there first the fluid display a crank that Parker's eyes up to five makes it easier for you guys to see but I'm gonna go to my scene I'm gonna go to the solver and yes we are using my own graphics card so that's all good okay so that that's all I did so we've got this film now and if I play this you'll see that these are just let that calm down a little bit so now we've got a body of water I'm quite happy with it's quite stable so we'll stop that there go to the fluid go to the fluid here and then we're going to create an initial initial state so we've created that and we also want to use it so this has got to be checked on now when I go to the beginning that's his initial state and Bob's your uncle so now we're going to have it interact or something so what I'm gonna do I'm gonna create a platonic here I'm just going to drag that up that's a little bit too big for what we need it for and I'm just going to shrink this down like this in fact as come out of this view and going to this one yeah that should be fine as it is actually maybe a little bit smaller something like that and just to make it a little bit more interesting so it doesn't look like it has such harsh edges I'm you know make it editable I'm also going to go into its into edge mode control lay and then I'm going to bevel these edges slightly just so it looks a little bit nice so we don't need that many edges either so let's bring those down now I'll do is yes all real good I'm gonna create another material I'm just going to create a new PBR material in fact I can actually copy the one that I've already got here and we'll call that red and let's change it to red and there you go well I mean the wrong channel there we want to be in the reflectance in the layer color I will make this red so something like that and we can go into the reflection and make it maybe a little bit shinier as well and we can whack that on our Platonic and I'm just gonna yeah that'll do for now so we've got this object just bring this down into our scene objects here now if I press play yet again nothing's gonna happen because that is just an object there so we need to give it a um a rigid de forma so let's create a rigid to format it gets created in the scene tree like before and we need to make this a child of our object so now it's a child we can press play and yet again other rules that min and it's because this needs to be linked to the gravity in the scene so if I actually look at this rigid body and go oh yeah is linked to the fluid gray but it's not actually tied to the gravity I can actually grab this rigid body and pull it into the gravity so now it will be affected by it how it falls and you'll notice they also interacts with the fluid as well but something else you might notice if we go into this side in fact why is it interacting with the fluid it's because the fluid was already existed in the scene so it automatically gets added if I remove this from my rigid body in fact can I put the gravity into the now I can't so yeah we did the right thing we put our rigid body into gravity say you know these things will happen if you look at our rigid body now on press play you'll fall but hasn't absolutely no link to the fluid whatsoever so let's grab our fluid and put it back in and now that's what course is this lovely splash there but you'll notice that it goes straight through the fluid and our Collider here as well it doesn't even see it bye and the reason for that is exactly the same reason if we um if we have a look at our Collider so this is our container here and we go to our collider tag this is the volume tag here's the collider tag we'll get two properties we've got this link to the fluid but none to the rigidbody so let's drag our rigidbody in there as well and we can play again excellent so now you notice if you get back to our other view that we have a platonic falling into our fluid boom I think kind of bounces on the bottom a little bit but it remains pretty static and that is because what is actually happening is there's an interaction between two fluids essentially and that's how real flow figures this out so if I go into this side view again and then zoom in you'll see that there's little dots in here and they're particles just like we have in our main container so if I go to rigid and go to display will crank up the particle size to five so you can see them and you can see there's some particles in there now and so basically let's have a look at the rigid body itself okay so we've got the resolution which is the same as you'd get in this fluid here we've got a resolution to in this we've only got the 0.5 so let's crank this up to five and you can already see that the resolution of this object is a lot better now and it'll probably improve the interaction as well so let's press play boom there you go and you also notice that we've got a density factor here now this is going to be important in a minute or a collision I'm gonna leave that aligned but I collision simulates the motion forces between different objects inside the same domain to avoid interpenetration they don't recommend values greater than 1 it's already set to 1 so let's just leave it there stiffness particles inside a rigid object always tend to maintain their original shape values less than 1 introduce a small amount of elastic behavior now as soon as we're using a rigid body and we probably don't want that you might do but I don't in this state in this case right so that's this dealt with down the bottom we've got something called the Skinner this is enabled by default it used to be I think that um you actually have to skin this yourself so if you go to realflow deformers you've got particle skinner here it kind of does it internally as part of the rigid body tank so you don't have to worry about this anymore so basically you know filter object with fluid and then it creates a skin based on your object kind of thing and you've got some parameters in there I'm gonna leave these alone to be honest down the search distance basically particles within this distance from the object surface inside and outside will be taken into account for the defamation underneath we've got max control particles here you can specify how many particles around an object's vertex are being used to calculate the actual defamation the default value where you give satisfying results in many cases but if you want a higher precision you can actually crank this up and outside control particles basically means that demons will only look at inside an object for vertex neighbour's particle when active particles outside the object will be considered as well again I'm going to leave that all aligned so in terms of our rigid body I think they're gonna be okay there but now I actually do want to talk about the density because obviously you can see that this falls it hits the deck you know it displaces the ball I has a little bit of a bounce but then it's not so exciting really I don't seem to have a lot of action going on with our fluid there you may need to dampen that down a little bit but and this has got a density of a thousand and if we look at our fluid that's also got a density of a thousand so if we want to do something simulate buoyancy we'd have to make our object that's falling into the fluid less dense so that's half the density and see what happens so that falls in I'm not quite sure why our fluids misbehave in there I seems to have calmed down a bit now but it still doesn't look like it's floating too much if we go into the side view yet we still see it's touching the bottom there so it's not particularly so let's bring this right down to 200 and go back it didn't seem to be much interaction with the water there either and let's have a look at our fluid our fluid probably need to our rigid body in it yeah that helped forgot about that yes so the fluid needs to see the rigid body and the rigid body needs to see the fluid and obviously we just talked about the collision day or a minute ago okay so let's try that again ah there we go now we're getting some floaty action it doesn't seem to be displacing the water anymore either so let's rewind and go back and it's probably to do with it some density I mean if I put this back up to 750 it probably yeah we got some displacement now again okay good good stuff so we want some kind of floaty action there so let's bring that down to 200 [Music] okay so now you can see it's actually bobbing bobbing on the surface of the water let me just come out the camera and the water seems to be pretty calm there okay yes so if we go into the site now that you can see there pops down this a little bit of buoyancy there we could even make this a bit more extreme so that we could see see even more so I'm going to change that to 100 go back to the beginning and there we go you can see there it's actually bobbing along in the water now and just to show that you know this object itself has an effect on the fluid that it's in and this fluid has an effect on this object I mean that's all obviously apparent because of its buoyancy at the moment but and we can actually add some another demon in here to make this a even more clearer so I'm just gonna go back to this view in fact I can do it from here now stop this rewind unless um let's get a demon in there so with real flow demon and yeah a bit of wind that'll be good so if we drag this up you can see that it's pointing downwards at the moment so that's some point this to its side like this and well let's just hit play and see what happens first not a lot it's probably not strong enough so let's go to the wind ah there you go so you'll see that the wind has got no link in here at the moment and if we look at the K volume in the gravity they've got they've got links so if I go to the wind I'm gonna have to drag my fluid into it so there we go so we've got a link to the fluid now excellent now I don't know if this actually needs a link to the rigid body because this fluid is also inside our rigid but I'm going to do it anyway so let's go to wind grab our rigid body and we'll put that in there as well so then it's all taken into account as you can see it's pushing the window the fluid up slightly there and we don't want that we want it to be a bound effect so let's go to our wind let's crank the strength up to maybe something like 200 there we go and you can see all the particles coming out the other side now I'm being killed off Shh like that that's probably a bit too high so maybe 150 something like that and it seems to be a constant constant force but let's bound to this force so let's take this back to the beginning I'm going to go into my wind and click pound it and as you can see we've got this sum we've got this comb now I'm not actually gonna mess around with that too much I don't think nope but you can see that when we press play now it's completely bounded but we can actually test if this has affects our our rigid body now by putting it here and you can see they didn't move it off and just as a little experiment I actually want to remove the rigid from from this and and you can see it didn't really have an effect we can um we can even crank up the force so it's ridiculous something like this no didn't have a an effect on that also this rigid does need to be inside this wind here there we go and we've got a lovely effect now and off it goes okay so let's get our wind strength back down to I think it was 150 and we can actually put this in the water here wrong button sorry guys Sunday that yeah and I can put it there drag it back a little bit so that's it's sort of influence if you like and let's give that a go see what happens oh we've had a crash so bear with me a sec okay sorry about that guys that I had a little bit of a crash there that's why it's always important to save or incremental safe so this is where we're at we've got the wind with our fluid and rigid in it we've got a rigid with our fluid in it you know just to make sure all these things you know react together and obviously our client has got a fluid and rigid in it as well so they can all interact with each other and I've just placed this wind in so let's just hit play see what happens so our object is falling in the fluid it doesn't seem to be affected by that wind or the sort of swirl of particles there in fact let's hide our wind so we can just get a better view what's going on let's go into our side view and zoom in slightly and it looks pretty much like it's just sort of sad the bottom not doing a lot so maybe our wind strength needs to come up a little bit it's a hundred at the moment let's put it up to 200 and see what that does so there's a lot more movement there and it seems like our density on this isn't working now I've had this I've had this before actually if we go to the rigidbody and just look at the density say hundred and fifty if I drop it down to a hundred and then press play it seems to react a little bit more correctly and you can see it's getting caught up in the swell now moving around it's been pushed up so not only is this affecting the particles but the particles are affecting it and that's because in our fluid we've got this rigid to say that there's a link between you know the rigid and the fluid and in the rigid we've got our fluid so there's an effect both ways if you like you know the fluid on the rigid and the rigid on the fluid and that's exactly what we want so I'm actually gonna cash this I'm gonna go to my scene cache and I'm gonna catch the simulation and uh I'll probably speak this bit up okay so our cache is finished let's get back to the beginning and you'll see that we actually have two Platonic Schnauzer bit confusing and that's because this rigid is cached so this sort of your Skinner is cache to up here and you can see that we've got an object that is completely cached in its movement is cached in fact let's have a look at the display you can see there it's a direct copy of this so that means if I hit the cached version what is playing now there so like let's just sort of sat there which is where so you actually want to be able to see this one and we can hide this one here so we can hide that from render as well and then we got our cached version and as you can see is getting caught up in the swirl moving around very good you can see that it has a little bit of a struggle at the beginning there in fact just to make sure everything's working is I wanted to I'm going to actually go to the scene and I'm going to cache the simulation again but I'm gonna change the density of this rigid body down to something ridiculous like 50 and let's let's do that let's see what we can get out there and actually let's have a look at our fluids density okay I might even reduce the resolution to 10 just to see what kind of thing we get there okay so let's go back to the scene I'm gonna catch the simulation again oK we've cached a simulation and as you can see up here we've got a second cache now um and that looks like that one's been hidden so I'm gonna get rid of that and see what kind of result we get from this oh that's a bizarre turn of events I think it's getting slightly confused yeah I think it is so what I'm gonna do is go to the scene remove cache yeah I'll remove the scene cache there we go and I'm gonna remove this cache as well and bring our object back so you can see that you know there's still a few things to figure out definitely okay that's more like it for the density that I've actually got on this rigid body now I'm just going to turn the rigid off and let this drop and yeah okay cool I just wanted to do that so I could create an initial initial State for this again I can see that we've okay yep okay so that's good I'm gonna turn the wind off as well while am I here just so I can get that initial state calm Wars okay so we'll let that chill out for a bit yeah something like that use the initial state create an issue of State go back to the beginning yep all good again so that means I can turn my wind on and my rigidbody and we're at 50 or might say that's 100 actually and fluids on 10 yeah okay so let's uh let's just cache this now that the scene cache simulation ok jobs are good in back to the beginning again we can see that we've got two here we can I'd that now and hit play and yeah there we go is getting swept up in there great so that's pretty much the sort of long and short of the the rigidbody stuff really obviously there's a lot more you can do it you can even have different fluids interacting different domains all that kind of stuff and I'm sure we'll go into that a later point sometimes I hope that and I hope that was helpful for you guys as always you can catch me on a digital meet dot uk' and you can find out the real flow tutorials there also on my youtube channel so like and subscribe that would be great you can also follow me on social media Facebook Twitter and the like they'll be links in the description and if you'd like to support digital me I've got patreon page too it's a dollar a month some extra content there and they'll be on screen at the end of the video and in a link in the description also I have a second youtube channel called beef doctor and it's primarily for game streaming so if you want to see that checked out - okay cheers for listening guys bye e [Music] [Music]
Info
Channel: DIGITAL MEAT
Views: 28,681
Rating: undefined out of 5
Keywords: Digital Meat, Digitalmeat.uk, Cinema 4D, C4D, Cinema4D, Digitalmeat, Greyscale Gorilla, GreyscaleGorilla, 3D, Workflow, Cinema 4D Workflow, C4D Workflow, Plugin, Plugins, Next Limit Realflow, Next Limit, Realflow, Real Flow, Realflow for Cinema 4D, Real Flow For Cinema 4D, Realflow Cinema 4D, Tutorial, Tutorials, Cinema 4D Tutorial, Cinema 4d Tutorials, C4D Tutorial, C4D Tutorials, Daemon, Particles, Realflow Particles, Solver, Realflow Solver, Granular, Granular Solver, Dirt, Sand, Snow
Id: yo5cwAqB_AI
Channel Id: undefined
Length: 27min 32sec (1652 seconds)
Published: Sat Apr 28 2018
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.