Function available in CINEMA 4D Prime, Visualize, Broadcast, Studio & BodyPaint 3D
Simple logo animation
We will continue with a very simple "real world" example: a log animation. This logo will consist of two text elements. The two halves of the word "Tutorial" will jump in front of the camera from both sides and eventually come to rest after a bit of secondary motion (this animation will be done manually). The second text element, the word "Animation", will drop onto the word "Tutorial" from above (squash and stretch will be applied here) and subsequently rotate around its center axis before it comes to rest. The animation sequence will last 2 seconds (60 frames), after which the word "Animation" will rotate for 3 seconds (150 frames). To make the animation a little more interesting we will also animate the color of the word "Tutorial" as soon as it comes into contact with the second word, which will help highlight this coming together of words.
Splitting up the sequences to be animated
We will begin by splittingthe animation up by setting the primary keyframes for our objects. Click on the icon below to open the Cinema 4D file we have prepared:
As you can see, simple control elements have already been added to the scene. The object "Tutorial" will be animated using the HUD element, Horizontal Spacing’, and the object "Animation" will be animated via a Parent Null.
The scaling of an object is better done using a Null Object because the original object will remain unaffected. In our example, we will use this method to create the squash-and-stretch effect.
In order to make it more recognizable where the beginning and end of each animation should be we will first add Markers to the Timeline. Add a Marker for the object "Tutorial" at frames 0 and 45 and name them "TUTORIAL_Start" and "TUTORIAL_End", respectively. To create a Marker, Ctrl/Cmd+click on the first row of the frame at which you want to add the Marker. A Marker can also be added to a layer (it will assume the given layer’s color) or filter it using the Layer Manager...’s parameters. Create a Marker at frame 35 and name it "ANIMATION>Start", and create another Marker at frame 60 and name it "ANIMATION>End". Finally, add another Marker at frame 40 and name it "Bounce". This Marker will serve as a place holder for the color change for the object "Tutorial". This is the point at which both objects will collide and we will use layers to create the color change.
Markers are very helpful in keeping a good overview of the original animation. Markers can also be repositioned, if necessary. The timing of an animation is often predetermined and Markers make it easy to define reference points for this purpose.
Animating the word, "Tutorial"
- To make the text animation begin out of view, set a keyframe at frame 0 with a "Horizontal Spacing" value of 1200. (Ctrl/Cmd+click on the animation circle in the HUD or next to the parameter in the Attribute Manager).
- Move the Timeslider to frame 10, change the "Horizontal Spacing" value to 0 and set a keyframe.
- Now we want the text to stretch back a little. Move the Timeslider to frame 15, change the parameter’s value to 50 and set a keyframe.
- At frame 20, set the "Horizontal Spacing" value back to 0 and set a keyframe. The text should again be in its original location.
- Set the "Horizontal Spacing" value to 10 at frame 25 and set a keyframe. You will notice how the stretching is less pronounced, which simulates a loss of momentum.
- Move the Timeslider to frame 39, change the "Horizontal Spacing" value to 0 and set another keyframe.
- Go to frame 35 and set the "Horizontal Spacing" to 2 and set a keyframe (the stretch effect is reduced drastically just before it ends).
- Finally, we will end the squash-and-stretch effect by changing the "Horizontal Spacing" value to 0 at 45 and setting another keyframe.
The image below shows the position of all keys and their respective values. The decreasing squash and stretch is represented by the "Horizontal Spacing" value’s F-Curve in the Timeline.
If you play the animation now you will notice that the movement is missing "personality". This will be corrected later using F-Curves. First we will finish organizing the animation itself.
Key presets were added to the kay values in Cinema 4D R17. These presets have Remove Overshooting enabled by default. The behavior of previous releases can be used by selecting all key values in the Timeline and setting Key Preset to Custom in the Attribute Manager.
Animating the word "Animation"
- Select the Parent Null Object () of the word ,Animation’ and move the Timeslider to frame 35. Set the Position Y value to 600 and set a key.
- Move the Timeslider to frame 40, set the Position Y value to 80 and set another keyframe (this is where the two words will collide).
- Select frame 45 and set the Position Y value to 250 and set a keyframe (this movement simulates the rebound).
- Move the Timeslider to frame 50, set the Position Y value to 150 and set a keyframe (this movement simulates a slight downward rebound).
- Finally, set the Position Y value to 155 at frame 60 to complete the movement.
Animating the rotation
- Select frame 60 and set a keyframe with the value 0° for the Null Object’s Rotation H (heading) parameter.
- Go to frame 90, set the Rotation H value to 360° (a complete rotation) and set a keyframe.
- With these two keyframes we have defined an animation of one full rotation. As mentioned earlier, this animation will be looped, which means a second complete rotation with a different interpolation must be animated to make this loop work (the first rotation starts from a complete stop, which cannot be used for a loop because a loop requires a constant velocity). Move the Timeslider to frame 120, set the Rotation H value to 720° and set a keyframe.
If you think the rotation animation is too fast you can increase the number of frames from 30 to 60 for a single rotation. We are using 30 frames to avoid long render times for this tutorial.
And finally, the color change
- Create a new material and assign it to the "Tutorial" object. Set the Color parameter to dark green. The Material Manager... can be opened via the menu or by pressing Shift + F2.
- Set a keyframe for the Color parameter at frame 0.
- Go to frame 40 and change the Color to white and set a keyframe. This is the moment at which the words’ collision causes them to change color.
- To speed things up a little we can copy the green we created and paste it onto frame 55. This will save you from having to create the color again.
You will notice that the keyframes for the animated Color parameter are not visible in the Timeline. This is because only the keyframes of certain objects are displayed in the Timeline and that the Timeline handles values from tabs differently. You can display the Color parameter’s animated values in the Timeline by right-clicking the Color parameter and selecting command. Note that this will change all your settings for the Timeline and should be reset back to their default settings (to do so, select from the Timeline menu).
You can create custom bookmarks for the Timeline
that you can use to jump to a bookmarked position along the Timeline or a bookmarked value. To create a bookmark for a current status simply click on the Add Bookmark
command. You can then make any changes you like and use the bookmark to return to the originally bookmarked state. Bookmarks can be renamed selecting the Manage Bookmarks...
- Since you can now edit the Tracks of this object’s parameters, press the Ctrl/Cmd key while dragging the key used to define the green color from frame 0 to frame 55, which will create a copy of this keyframe (one keyframe for each RGB value exists).
Play the animation and you will see that a color change slowly takes place between frame 0 and frame 40. The color value should be maintained until it abruptly turns white at the second keyframe. Sound familiar? This is exactly the effect achieved using the Step Interpolation mode, which needs to be taken into account when adapting the F-Curves.
So much for splitting up the animation. All necessary keyframes have been set and the general timing for the scene has been maintained. We can now start fine tuning the animation by adjusting the F-Curves. All that needs to be done now is to record the keyframes for the squash and stretch motion of the object "Animation" when it collides with the other word. It’s a good idea to create a preview of the entire animation at this stage in order to get a better feeling for the overall movement and timing to this point (depending on the scene, your computer might skip frames in order to maintain the desired frame rate, which is why you should not necessarily depend on the Viewport display when testing an animation’s timing or overall motion).
F-Curves can be used to make an object’s motion more dynamic by modifying their shape, which will increase or decrease the speed of an object’s motion at specific locations. Some additional, finer movements can also be used to refine the object’s movement. First you should define which objects’ movement should be refined:
- The object "Tutorial" jumps too far and too softly. The letters should bounce off each other and not overlap (the direction of movement should change abruptly and not gradually).
- The color of the object "Tutorial" should be maintained from frame 0 to frame 40 and change when it is impacted by the object "Animation".
- The object "Animation" falls a little too far (overshoots) and intersects with the "Tutorial" object. We also want to have it rebound correctly when both objects meet.
- The rotation should begin more slowly and end with a more constant velocity for a more optimized transition for the repetition.
- The squash and stretch of the "Animation" object still needs to be added, which will make the rebounding movement much more dynamic.
- Finally, the repetition of the rotation will be created using a Motion Clip, which will be done in the last chapter of this tutorial.
To begin with this section of the tutorial, open the following file. It contains the keyframes from the previous section:
Animating the word "Tutorial"
- Select the "Tutorial" object and switch to F-Curve mode (you can switch modes by pressing the Tab key).
Since we want to change the movement’s characteristic we will modify the curve manually. Press the Shift key while dragging the second key’s hanld to create a more abrupt transition (the key’s numeric value will change accordingly).
Play the animation. You will notice that it now looks like the letters actually bounce off of each other upon impact. We don’t have to repeat this process for the other keyframes because the overshoot only takes place at the first keyframe.
Coloring the word "Tutorial"
- Switch to the bookmark you previously created for the animation of the material color.
- Select the first keyframe and set its Interpolation mode to Step (alternatively you can change the Interpolation mode by pressing Alt+t on your keyboard). By switching to Step mode, Cinema 4D will maintain the value of the first keyframe until the next keyframe is reached. In this example, it means that the color of the "Tutorial" object will stay green until frame 40 is reached at which point it will abruptly turn white and gradually turn green again by the time frame 55 is reached.
Positioning the word "Animation"
- Select the Null Object to display its F-Curves (again, you can switch to Default Bookmark or your another bookmark you created).
- This object should also rebound upon impact. This will require a similar movement to the movement of the other word object, only that this time the Y position will be modified. Select the second keyframe and Shift+drag its grabber to create a sudden change of direction as shown below (try to make the curve as smooth as possible so the animation runs smoothly as well).
Rotating the word "Animation"
- All we have to do here is adjust the Heading (Rotation H). Select the rotation Track in the Timeline to make its curve visible in F-Curve mode. Select the last two keyframes and set their Interpolation to Linear in the Attribute Manager settings (alternatively you can press Alt+L on your keyboard). This will ensure that a constant velocity is maintained between the keyframes.
- Next, we have to create the constant, continuing rotation itself. In this case it would be easiest to activate the entire Function Curve by double-clicking on it and select the Continue After command from the menu. This function allows the curve’s animation to be continued through to the last set keyframe. The rotation will be continued with a constant velocity after the last keyframe.
In the next section of this tutorial you will learn an alternative method of creating such an animation: Motion Clips. Although using Motion Clips would be too complicated for the animation we just created, they are an excellent method of animating entire animated hierarchies or characters.
Scaling the word "Animation"
- We will now create the squash and stretch effect by scaling the object. Select the "Animation" object’s parent Null Object and set a keyframe for the X and Y Scale parameter at frame 39 (if the object’s height is squashed the object’s volume needs to be maintained, which is done by adjusting the object’s width accordingly). This effect can be seen when a pillow is squeezed - it stretches in the direction of no resistance.
- Go to frame 40, set the Scale X and Scale Y values to 1.2 and 0.6, respectively (this will widen the object (stretch) to compensate for the reduced height (squash)). Set a keyframe.
- Select frame 42, set the Scale X and Scale Y values to 0.9 and 1.6, respectively and set a keyframe (the object is now stretched vertically and its width has been reduced accordingly).
- Finally, Ctrl/Cmd+drag the keys for the Scale X and Scale Y values from frame 39 to frame 45 (this will copy both keys to frame 45 with the default value of 1).
The animation is now complete. Render a video and compare your result to the following video: