Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Maxon Cinema 4D Bouncing a ball into a hole

  • Bouncing a ball into a hole

    Posted by Robyn Rhodes on January 10, 2011 at 10:26 pm

    Hi, I would like to bounce a sphere from off camera upstage(theater lingo) left, and bounce into the center of the bullseye, also I would like the ball to squeeze through the hole as if it’s a little too fat to go through. I’m not sure if the squeeze would really be that noticeable as the ideal rate the ball is traveling would mean that there would only be a 2 or 3 frames @30fps of actual deformation as it goes through. One other detail is that I don’t want the ball to deform too much as it bounces off the floor once, before it gets to the hole. Maybe I would animate “shape conservation” to achieve this? Lastly I want to use a floor for the infinite horizon look and to bounce the ball of of, but I also need to have the center be a tube into which the ball goes. Is there a way to mask part of the floor so that the depth of the tube doesn’t get cut off by the floor? Or maybe there’s another environment setup that does not use a floor that achieves the same look. In the scene file, the floor has been turned off. If you turn it on you can see the issue.

    I have included a link to a reference animation which I’ve done to illustrate what I am after:

    https://files.me.com/mr27/wf9hiq.mov

    Link to scene file:

    https://files.me.com/mr27/8d4dwv

    Using R12
    12 Core MacPro

    Thanks!

    Robyn Rhodes

    I’m only half the thing I say I am, the other half are me.

    Robyn Rhodes replied 15 years, 3 months ago 2 Members · 5 Replies
  • 5 Replies
  • Adam Trachtenberg

    January 10, 2011 at 11:02 pm

    I’d probably use the squash & stretch deformer instead of dynamics for this.

    As far as the floor goes, you might be able to get away with using a very large plane instead of the floor object. In that case you could use a boolean to creat the hole. If you really must use the floor object you can create a hole with a circular gradient in the alpha channel … but it’s a bit tricky to get it placed right. Basically it works like this:

    1. Create a texture with a circular gradient in the color channel (easier to see) and place it on the floor. Set to flat mapping and turn off tiling. Now use the texture axis tool to move and scale the gradient over the hole;

    2. Copy the gradient parameters;

    3. In the real floor material, create an alpha channel, add a gradient to it, and paste the parameters from the other gradient;

    4. Load an Effects>Projector shader, which will automatically reference the gradient shader;

    5. Lock the Attributes manager select the texture tag you created in step 1. Now, in the projector shader, click the “paste tag” button.

    6. Now you can set the UV projection for the floor material’s texture tag to whatever you like and the projection for the alpha channel will remain frozen over the hole.

  • Adam Trachtenberg

    January 11, 2011 at 12:17 am

    A couple of other thoughts on your file:

    1. The alpha method obviously isn’t going to work with dynamics, so the floor can’t have a dynamics tag;

    2. That’s okay because the first couple of tube objects should be sufficient for the going-down-the-hole part. If you use dynamics for the bounce you can just switch it off for the floor before it goes down the hole;

    3. For the Tube objects, you should switch the collision>collision shape to static mesh. If you leave it on authomatic the simulation isn’t going to see the hole.

  • Robyn Rhodes

    January 11, 2011 at 12:25 am

    Thanks so much Adam.

    One thing I’m not sure how to do is how to get the ball to go to the location of the hole. Is there some kind of target you can set up in dynamics?

    again my gratitude.

    I’m only half the thing I say I am, the other half are me.

  • Adam Trachtenberg

    January 11, 2011 at 5:22 am

    If I was you I would move the hole to the ball. 😉

    You could use an attractor but it probably wouldn’t look natural.

  • Robyn Rhodes

    January 11, 2011 at 5:47 pm

    Schöpfergeist bist du! 🙂

    I’m only half the thing I say I am, the other half are me.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy