My first Animation

This document is about how to create your first Animation using Avastar. For the begin we will create a three frame animation. This is just to get you started. As your experience grows you will learn much faster ways to pose and animate your character.

I assume you have already installed Avastar. And i assume you have some experience with Blender.

For the technician: Avastar supports .bvh and .anim format. Both formats are fully supported by Secondlife and compatible target worlds.

Preparations

How to add a new Avastar Character

Now we switch to Blender’s default Animation screen. You do this from the Top menu Bar.
Note: Of course you can switch to whichever screen you prefer instead. But note that you will want access to the Timeline, the 3D View, the Dope Sheet and the Properties Editor.

Details about the Animation environment

Here is an overview of Blender’s default animation screen:

In the Dope Sheet switch the Mode from Dope Sheet to Action Editor with the pop up menu in the header.

Hint: If the Mode Pop up menu does not display, then move the mouse over the menu bar of the Dope Sheet window, then press middle mouse button and while keeping the MMB pressed, drag to the left side.

In the Action Editor mode you can create new Actions. You find the corresponding pop-up menu in the Dope sheet menu bar:


Press the white plus sign to get a new action and name it “FirstAnimation”.

Remind: If you do not find the Actions menu on your screen, then MMB -> drag to the left (as described above)
Hint: you can edit the action name right inside the pop-up menu.

Adjust the timeline

On the Timeline click on the first frame of your animation, for this animation set it to zero. You can do that either by dragging the green progress indicator until the position indicator displays “0”, or by immediately typing “0” into the position indicator as marked on the image below.
Hint: Use the scroll wheel on your mouse to zoom the timeline in and out and the middle mouse button (or hold down Alt) to pan.

 

Create the Start frame

I assume that you are still in Object mode now. In the 3D View make sure that you selected the armature by right-click on one of the rings surrounding the avatar. The rings should now appear in bright orange.

Then switch to Pose Mode. Now all Skeleton handles appear in a green color. You can select any of these handles and move them and rotate them as you like.

However while playing with the Pose you will note that we have placed a few constraints to the various parts of the skeleton. We did this mainly to keep you from ripping the character into pieces by dragging the bones to unrealistic positions.

Note on Rotation

The easiest way to rotate the bones is to use the rotation manipulator controls. For your first steps you may want to select the curve segment in the 3D Manipulator widget so Blender will show the rotation manipulators when you select a bone:

You may want to use the Rotation mode “Normal”. I found this the most convenient mode when working with the mouse.

As you get more experienced with Blender you will use keyboard shortcuts more and more. Maybe you will even skip the 3D Manipulator after a while when you realize how efficient the usage of shortcuts actually is.

More Animation details

More about Rig Display Properties

You have full control over which parts of the Rig get displayed at a given time. You find the Rig Display control panel in the Object Data section of the Properties panel. Below you find a comprehensive documentation.

More about the Rig Display

More about the Skeleton

As explained above we can now move and rotate the skeleton as we like. We see that the mesh moves along with the bone movements and we will finally end with our start pose for frame zero of the animation (where you want the bones for the start pose) Remind that we are only moving and rotating the green skeleton handles for now.

SL Control Bones

All the green skeleton handles are the SL Control Bones and act as FK (forward-kinematic) controls. They have just been given funny shapes so they lie outside the avatar and are less visually distracting. When an element displays in light green then it is selected and will react on your move, scale and rotate commands. You can select single bones by right-click, or add bones to the selection by SHIFT right-click.
img-1-002

The Control Bones (and the IK Bones) are used for Animation.

The Avastar Skeleton has 2 more Control Bones with very special properties:

The COG

Center of Gravity bone. Use this bone to set the location and rotation of the character. Avastar adds the COG bone movements to your animation. the COG movements are later mapped to the mPelvis bone of the target skeleton.

The Origin

All movements are relative to the Origin bone. Moving this bone around will not affect the animation in any way. If you are doing multiple character animations set their origins slightly apart to where pose balls would start. Once you are happy with the location hide the bone.

SL Base Bones & Collision Volumes

Besides the (green) SL Control Bones we find many other bones in the Avastar Rig. We especially have two subsets of bones named the (blue) SL Base Bones. and the (orange) Collision Volume Bones. These 2 subsets of Bones are only used for weighting (skinning) your character or attachment. But they are never(!) used for animating your character.
2-2

Never directly use the SL Base Bones and the Collision Volumes for animating! You create Animations only with the green Control Bones and the IK Bones.

Mandatory rules

  • Weight only the blue SL Bones (and the orange Volume Bones).
  • Animate only the green bones (and possibly the IK Bones).
  • Never add weight to the green SL Control bones.
  • Never use the blue SL Base bones for animating.

Store the Intro Pose

Once you are happy with your first frame posture press the a key twice in the 3D View to select all bones (it toggles the selection so the first time it will deselect everything if you had a bone selected). The Rig should now look like what you see on the image to the right.

Now press i to insert a new key frame. From the appearing pop-up menu select Rotation (see image below).

Almost always you will set just rotation key frames. The exception is if you are moving the COG or IK control bones, in which case you should set the location too with Location or LocRot for both.

Note: You do not need to create a starting T-pose. The .anim format doesn’t need it and Avastar automatically inserts the required reference frame for the BVH format.
Important: Never use the Keyframe option Whole Character! This option would insert keyframes for all 139 bones (visible and invisible). The Avastar Animation exporter will complain about too many bones in Animation.

The Action Editor

You should see the Action Editor gets populated with the bone names and a yellow diamond at frame 0.

Note: We have simply selected all bones for our pose. This poses a potential problem:

Assume that you wanted the current animation to play “on top of” your default stand pose. In the Stand pose the avatar head moves freely. But after you add this animation, the head no longer moves freely as before. It now moves according to this animation and so the animation “overrides” the default head movements. If you do not want to override the head animations, then you have to remove the head data.

The easiest way to do that is to left click on the corresponding Bone name in the Action Editor (“Head” in our example) and then drop the entire bone from the animation (press “x” on the keyboard).

Note: You can also “mute” the bone by clicking on the little speaker icon next to the bone name. If a bone is not listed in the action or when it is marked as muted it is not controlled by the animation.

Note: In more advanced work you can play with creating sets of animations which control only a few bones each, and which you can mix and match with the Gesture editor in Second Life.

Add the Ending Pose

  1. Lets imagine the animation will run at 25 fps. Click on the timeline on frame 25 which is one sec later (see image below)
  2. Repose the avatar how you want it to appear one sec later and again select all the bones and insert a rotation key frame (‘a’ to select all and ‘i’ to insert key frame). Do something simple like a bow or a hand wave for your first animation.
  3. Click on the timeline at 50 (two secs into your animation), then pose and key frame the bone rotations for the last frame.
Hint: In the Timeline use the play buttons to preview your animation:
Hint: You also can scroll through your animation by grabbing the green time locator and drag it from left to right and back.When you want to set intermediate key frames, then just move the time locator to where you want to add a key frame, then adjust your pose and finally press a twice ( to select all bones) and then (and select rotation)
Hint: You can drop a keyframe with ALT+i but take care here: This will only work when you have selected the bones which you want to remove from the time line. You can always first select all bones, then ALT+i to make sure you remove the entire key frame.

Prepare the Export for BVH

You find the “Animation Export” panel in the Render Properties section of the Properties window.

  • Make sure the mode is BVH
  • set the FPS to 25
  • Set the Start frame to 1
  • Set the End frame to 50.
  • Make sure to check the Prepend reference.

Prepare the Export for Anim

You find the “Animation Export” panel in the Render Properties section of the Properties window.

  • Make sure the mode is Anim
  • set the FPS to 25
  • Set the Start frame to 1
  • Set the End frame to 50.
  • Enable Loop animation
  • Set In and Out for the loop both to the last frame.

Export the Animation

  1. Finally, export the animation by clicking on the Export Animation button. Avastar asks you for a filename and location which by default will take on the name of the action you set before.
  2. Once saved, fire up your Viewer, and from the file menu select Upload then Animation. Find and upload your animation, it will appear in your Animations folder. During upload you will have to choose the  priority.
  3. Run it and show off your creation.
Note: If you don’t see the animation play out, you may need to switch off your AO. This happens if the animations in your AO have been badly designed and are running at the highest priority).

 

This tutorial has only scratched the surface of what is possible. Things you will want to explore next are using the IK controls, looping part of the animation, animating only certain bones, using the Graph Editor… Feel free to download my own firstAnimation with Avastar.