Self-paced training: Modeling

Animation, Relations, and Dynamic Positioning

Description: 10 minutes; Lab exercise: 60 min

Quickly create sophisticated animations, define new relation types for your assemblies, and put them together for animated analysis and demonstrations of your designs. Dynamic Positioning has been streamlined, and you can now add constraints to Relations when you move objects.

These three topics are presented together in this document.

The new Animation module and changes in Relations provide new and improved functionality that will help you with many tasks, but they have the most impact when used together.

Animation and Relations changes include

The new Animation module

Animation capabilities have been part of the Dynamic Relations module for some time. This functionality allowed you to create simple animations, but creating anything beyond a simple animation required complex relations definitions.

The new Animation module allows you to create complex animations with relative ease, and to save the animation as an AVI file to share with others. You do not need to create any relations to use the module, but you can use relations and they may simplify your work. Additionally, three new relation types were created specifically for use in animations.

New relation types

Three new relation types have been added so you can easily define complex relationships between parts. These three relations are Gear, Rack, and Cam.

The new relation types are shown in the image above:

Changes to (Dynamic) Relations

Dynamic Relations has been improved and changed over the last two major releases. For OSDM 2004, it was split into two modules: Assembly and Parametric Relations. For OneSpace Designer Modeling 2005, we've simplified the name to Relations, and further split the two types of relations. Now the menus are different, because of the fundamental differences between assembly and parametric relations. We've also completely rewritten the documentation to reflect all these changes and improvements.

Support has also been added for relations with additional geometry types:

The dialogs for creating or modifying relations will guide the user as to what is possible. For example, if a straight surface and a torus is chosen for a coincidence relation, the focus will be the torus center, axis, or plane, because it is not possible to make the straight surface coincident with the torus surface.

Only a limited range of relations will work for bsplines, intersection curves, and spun surfaces. For example, you cannot make two spun surfaces coincident (even if they have the same base curve). This is a limitation of the 3D DCM (library from D-Cubed used in relations).

Changes to Dynamic Positioning

The following changes have been made to the Dynamic Positioning dialog:

 

Lab exercise

This lab provides an introduction to using the Animation module, the Dynamic Relations additions and changes, and the new dynamic positioning functionality. You will create a basic animation, then increase its complexity by adding relations. This lab includes the following sections:

Prerequisites

Before you begin these exercises, you should have

You do not need to know how to use the animation functionality in previous releases.

Start the module and load the model

Before you can create an animation, you must have the Advanced Assembly module activated. You also need to have a model loaded and the relation set(s) you wish to use must be updated. If you haven't downloaded the PKG file used for these exercises, please download it now.

  1. Click Application > Modules.

  2. Turn on Advanced Assembly in the Advanced Modeling tab.

  3. Load the example file cam_gear_rack.pkg.

  4. Make sure rset1 is the active relation set.

  5. Click Assembly Rels .

  6. Click Update.

If you cannot activate the module, you may not have an Advanced Modeling license.

Create a simple animation

First we will create a simple animation. When you create an animation, you will specify an owner. The owner can be any assembly, but the relation set(s) you use in the animation must be at the same level or below the animation.

Watch a video of this step

  1. Turn off the display for the part named guide, which is in the assembly base_unit.

  2. Zoom in on the blue part named cam.

  3. Click Animation .

  4. Click Define.

  5. Click New Anim.

  6. Select the top-level assembly, named animation_assembly, for the Owner.

  7. Click Accept.

  8. Do not click yet!

You should see your animation in the structure browser window. It is identified by this icon:  

Add relation set and control positions

Animation movement is interpolated from control positions. You position your parts where you want them to be at each stage and capture them as control positions. You can move multiple parts for each control position. The movement of the parts between these positions is interpolated.

When you move parts to define an animation, you are not making permanent positioning changes to your assembly or parts. All parts will return to their original position when you are finished defining or playing an animation.

For this lab, you will use relations to produce complex movement. You can solve more than one relation set in an animation, but you can only solve one relation set at a time. For this exercise, you will only worry about one relation set: rset1.

Set the relation set to solve, then capture four control positions:

Watch a video of this step

  1. Click Solve in the Relation Sets section, then select rset1I. You'll add relations to this set later which will make your animation work like the one shown in the example at the beginning of this document.

  2. Click Rotate in the Dynamic Methods section.

  3. Rotate the cylindrical hole in the blue cam part 90°. The direction is not important, but you should turn the part in the same direction for all four control positions.



    Tip
    : Click on blue sphere, shown in the image above, if you need to set the part back to its original position and cancel the dynamic positioning operation. The blue sphere works to reset positioning anywhere dynamic positioning is used.
     

  4. Click Capture Position.

  5. Repeat steps 3 and 4 three more times, until you have turned the cam around 360°.

  6. Click to finish defining the animation.

Play the animation

That’s it! Now you get your first look at the animation:

  1. Click Animation  .

  2. Click Play.

  3. Double-click the new animation in the structure browser window.

  4. Click the play button in the animation controls box, which is described below.

As you can see, the slider bar in the animation controls box shows you how many control positions you recorded in your animation. This control is similar to other media players, with familiar icons for playback:

sets the position at the beginning of the animation.

takes you back one control position.

plays the animation from the current control position to the end.

stops an animation while it is playing.

moves the animation forward one control position.

moves the animation to the end.

 

You can use the slider bar to move forward and back through the animation at one tenth increments.

The next section down in the menu panel contains positioning sequence information. Although we only created one sequence for this exercise, you can record your animation in a series of sequences.

Use positioning sequences to organize long or complex animations; this will make it easier to find a particular control position or where you solved a relation set.

The Play Options section allows you to set

Analyze the model with Animation

Animation is a useful tool to detect clashing. The Clashing section of the Play Animation menu panel provides two options:

The clash detection capabilities can fail to detect a problem if the playback speed is set too fast or if the accuracy is set too low. Set the speed or accuracy in the Play Mode section in the menu. Use Analyze and its accuracy settings when you want to detect clashes; use Real Time and its speed settings when you create an animation for demonstration.

Try turning on first Show, then Stop, and see what happens when you play the animation. You should find a clash between the blue cam and the yellow lever.

Add a Cam relation

The example model contains four Assembly Relations that have been created for you. These relations are necessary for the model to animate properly.

As mentioned in the overview, three new relation types were added for this release: Cam, Rack, and Gear. We will add them one at a time for these exercises, so you can see exactly how each relation behaves.

A Cam relation is defined between one radial or spherical surface and a series of tangentially connected faces. Create the cam relation:

Watch a video of this step

  1. Click Assembly Relations .

  2. Click Cam in the Advanced section.

  3. Select the cylindrical face on the yellow part named rack for Elem 1, shown here:

  4. The Select dialog will open. Select the four adjaClick Assembly Relations .

  5. Select the adjacent faces on the blue part named cam for Cam fcs, shown here:

  6. Click End in the Select dialog.

  7. Click to complete the relation definition.

  8. Click Update in the Solving section of the menu.

Now play the animation again. The yellow part named rack should move in response to the rotation of the cam. If the animation does not move, make sure Stop in the Clashing section is not checked.

Add a Rack relation

A Rack relation is defined between a radial element and a linear element. Create the rack relation:

Watch a video of this step

  1. Click Assembly Relations .

  2. Click Rack in the Advanced section.

  3. Select the cylindrical face on the red part named red_wheel for Elem 1, shown here:

  4. Select a directional element on the yellow part named rack for Elem 2, shown here:



    Tip
    : Any planar element, such as a planar surface or a line, will be accepted for Elem 2. However, a planar surface may not animate correctly. For the best results, select an element that has a clear direction, such as a line.

  5. Click Animate to check the rotation and movement direction.

  6. If necessary, click Flip Dir to reverse the direction of movement.

Note  Fixed Axes determines which part moves. If Fixed Axes is selected, Elem 1 (the cylindrical element) rotates and Elem 2 (the directional element) moves in a linear direction. If Fixed Axes is not selected, Elem 1 will roll along Elem 2, and Elem 2 will not move. However, constraints placed on either part by other relation definitions will affect the movement. In our example, other relations on the assembly keep Elem 1 (the red part) stationary.

  1. Click to complete the relation definition.

  2. Click Update in the Solving section of the menu.

Play the animation to see your progress.

Add a Gear relation

A Gear relation is defined between two radial elements. Create the gear relation:

Watch a video of this step

  1. Click Assembly Relations .

  2. Click Gear in the Advanced section.

  3. Select any cylindrical face on the red part named red_wheel for Elem 1, shown here:

  4. Select any cylindrical face on the green part named green_wheel for Elem 2, shown here:



    Tip
    : Although you can select any cylindrical face for a gear, if you select the outermost faces, your turning ratios will be more accurate.
     

  5. Click Animate to check the rotation direction and ratios.

  6. If the rotation direction is not correct, select Flip Dir.

  7. If the rotation ratios are not correct, your parts will not appear to move together. Change R1 and R2 to adjust the ratios.

  8. Click to complete the relation definition.

  9. Click Update in the Solving section of the menu.

Now when you play your animation, it should look like this:

 

Create an animation using Dynamic Positioning

When you animated cam_rack_gear.pkg, you did very little positioning to set the assembly into motion. Now you will animate the the gears and rack without using Relations. You will not animate the cam for this lab, because it cannot be done smoothly without using the relation type.

  1. Click Assembly Relations .

  2. Click Delete in the Edit section.

  3. Delete the cam, rack, and gear relations that you defined earlier. Do not delete any other relations.

  4. Click Update in the Solving section.

  5. Hide the entire base_unit assembly.

  6. Move the yellow rack part:

    1. Click Part & Assy .

    2. Click Pos Dynamic in the Modify section.

    3. Select Line/Axis.

    4. Select Update Relations.

    5. Move the yellow part so it is positioned like this:

    6. Click to complete the operation.

  7. Create a new animation, like you did in the previous exercise. Click here to review the instructions.

  8. Position parts for the first control position:

Note  If you rotate an object 180° or more, the direction of rotation is interpolated and may not move in the direction you intended. You should rotate objects in increments less than 180°.

  1. Click Capture Position.

  2. Repeat the positioning in step 8 and capture a second position.

  3. Click (the large arrow) to preview the animation.

  4. Click to save the animation.

Play the animation. If you need instructions, you can review them here.

Modify a control position

The numbers displayed in the Navigate section indicate the time in seconds, and are not control position numbers. The only way to navigate to a control position is by using the forward and back arrows.

Each control position has a delta time. The delta time is the time from the previous control position to the end of the current control position. By default, the delta time corresponds to the insert time. You can increase the delta time, which slows down the movement from the previous control position to the current control position. You can set the delta time to any number greater than zero (0).

Lets modify an existing control position to slow down the first half of the animation.

  1. Click Animation .

  2. Click Define.

  3. Select the second animation you created.

  4. Use the forward arrow (the small ) to move forward in the animation to the first control position (which happens to be at 1 second).

  5. Select Modify in the Snapshot section.

  6. Type 10 for the Delta Time and press Enter.

  7. Click to save the animation.

You'll notice that the Navigate section now displays 13 on the right side of the slider. This tells you the animation is 13 seconds long, but there are still only two control positions in the navigation. Again, the only way to see where control positions are located is by using the forward and back arrows.

If you use the forward and back arrows in the navigation controls to move through the animation, it jumps from 1 to 11. That's because you defined control positions at those points, and changed the time on the second control position.

Delete a control position

When you delete a control position, you can remove the control position for as many parts as you like. You can also choose to

  1. Click Animation .

  2. Click Define.

  3. Select the second animation you created.

  4. Add another rotation, so you now have three control positions and the animation is 14 seconds long.

  5. Click to save your changes.

  6. Open the same animation and navigate to the second control position (at 13 seconds).

  7. Click Delete in the Control Positions section.

  8. A new section will open at the bottom of the menu.

  9. You can select

  10. Select All and Shorten animation.

  11. Click to save your changes.

Play the animation to view the effect.

Export an animation

You can export animations as AVI files on Windows only; you cannot export AVI files on UNIX. Several AVI codecs are defined in the animation customization file. Please refer to the next section for information about changing the customization file.

  1. Click Animation .

  2. Click Play.

  3. Select your Animation in the Structure Browser.

  4. Type or browse to set a File name.

  5. Select a Screen Size.

  6. Set the Frames/Second. 25 frames per second is the maximum most media players will accept; choose fewer frames per second only if you need to create a smaller file.

  7. Select a Codec.

  8. Set the Compression. You should accept the default value unless you are concerned about the size of the AVI file. If the AVI codec supports compression, higher compression may create a smaller file, but with lower quality.

  9. Click to save the AVI file.

Animation customization

You can define and set several default values in the Animation customization file. You can find this file in personality\sd_customize\AdvAssembly_Parametrics\ani_customize.  

The following functions allow you to define defaults in this file:

Review online help

For more information about Animation functionality, please open the OneSpace Designer Modeling online help and click on Modules > Animation in the Contents pane.

If you need more information about control positions, please review Animation of a 100m race modeled in OSDM 2005, which was created and is maintained by Customer Support.