Join EJ Hassenfratz for an in-depth discussion in this video Pop popcorn using Emitter and Dynamics, part of Motion Graphics Weekly.
- [EJ] Welcome to Motion Graphics Weekly, where you up your MoGraph knowledge on week at a time. I'm EJ Hassenfratz. Let's get our learn on. In this video, I'm going to show you how you can use emitters and rigid body dynamics to create a fun animation of popcorn popping inside of Cinema 4D. So here is our scene. We have our popcorn box. We have our little kernel of popcorn. Let's create a whole bunch of these popcorns using an emitter object.
So we're going to go up to Simulate > Particles > Emitter. Now for emitter to emit an object, we simply have to place that object underneath as a child of the emitter, and let's actually move our emitter up here so we can see it. There we go. And we'll hit play. And you're going to see that all we see are these little particles being emitted and none of our popcorn, and that's because we need to turn on Show Objects, and that will actually show the geometry of the object of the child of our emitter.
So now we can just rotate this 90 degrees upwards, like so, and we can move it down right about there, and what we're going to do is make these pieces of popcorn dynamic so they have real-life physics applied to all of these kernels, and to do that, I'm just going to right-click on our popcorn, go to Simulation Tags, Rigid Body, and let's see what happens here.
I'm going to hit Play, and you're going to see, we have a bunch of popcorn popping, but none of our popcorn is actually staying inside of our box. Our popcorn box, and the reason for that is is that we have no dynamics tags applied to our popcorn geometry, so it's excluded from the dynamic simulations. So to add it as a collider object, we actually don't need any gravity or anything applied to our box. We just need it to be recognized as an object to be collided into.
So I'm just going to right-click on the popcorn box, go to Simulation Tags > Collider Body, and that will allow it to be collided into. But we have an issue still, and that is that nothing changed. And the reason for that is that this Popcorn Box Null has all this geometry of our popcorn box underneath it, but the Dynamics Tag by default does not recognize anything underneath until you change some of its collision settings. So what we need to do is we need to adjust the Inherit Tag so that dynamics properties will be inherited by either the children or it's just one compound collision shape.
So what I want to do is actually just make this one compound collision shape, and let's hit play, and you'll see that it's getting collided into here, and we have popcorn actually filling up our popcorn box. Let's actually move this all the way down, and you can see that our popcorn is filling up our popcorn box geometry. Let's create a lot more popcorn kernels by upping the particle birth rate in both the editor and the render.
Now the party's starting. We got a whole bunch more popcorn being popped, and it's being all contained inside a popcorn box geometry, and we can actually introduce some rotation so it looks a little bit more organic by upping the rotation value here, so say 50, and then we can change the variation, which just adds variation to the rotation speeds. And you can see, now we have some rotating popcorn happening here, and you can see that some of our popcorn's just flying all over the place.
If you actually want to try to constrain that so the popcorn's not popping all over, we can actually introduce almost like a helper rigid body dynamic object, and by helper, I mean that we can use something like a hemisphere, if I bring a sphere and change it to hemisphere, you can kind of put like a helmet on the popcorn box to try to keep all those kernels inside there. So, we can also apply a Rigid Body Dynamics Tag to this hemisphere or a collider body, since we just need to be collided into.
The only problem is if I hit Play here, the only problem is that by default, this isn't recognized as a hollow object or a concave object, and that is because, by default, this shape is set to automatic, and what that means is it basically puts shrink wrap around your geometry, and what that does is it totally disregards any kind of concave shape or hole in your geometry. So it won't recognize the inside of our hemisphere until we change this collision shape to something more accurate, and one of the most accurate is this static mesh.
If you don't have your geometry moving, you want to do a static mesh. If this hemisphere was animating, we'd want to do a moving mesh. So we're just going to stick with static mesh, and now, the dynamic simulation should recognize the hollow shape of our sphere. You can see now our popcorn's kind of popping underneath, and if I go and turn on X-Ray, we can see what's happening inside here. We can try to keep all this popcorn inside our popcorn box here.
We can see that by using this guider dynamics object, we're trying to constrain all those popcorn kernels inside there. So we can actually have these popcorn fly a lot more if we go to our emitter, and let's just bring this birth rate down to, say, 40, and let's adjust the speed so we can have these popcorn kernels really shoot up fast, and we can also introduce some variation to that speed, so some random variation. So we'll do 30%, so a little bit more organic.
So we have all these particles popping up. There's a lot more speed behind it, so we have a lot more popcorn actually colliding with our hemisphere object there, and this is looking good. One last touch. We can add a disc for a floor, so we can actually have these popcorn kernels hit the floor, and again, we'll go and include this in the dynamic simulation by going to Simulation Tag > Collider Body, and one thing we can use for this floor is introduce some friction so we can start to slow down those popping kernels so they're not sliding so much, and let's actually just get rid of this sphere so we can...
We want all these popcorn kernels to fly out. You can see that once these kernels fall, hopefully the friction of that floor should take over and slow down our kernels moving. We can also go to just our popcorn Dynamics Tag and up the friction on the actual kernels as well to try to slow things down, because popcorn really doesn't slide. So there we go. Once these popcorn kernels fall, they should come to a rest fairly quickly. That's looking pretty good.
So by using an emitter, a combination of dynamics tags, both rigid body and collider objects, we can create some fun popping popcorn in Cinema 4D.