From BlenderWiki
Si usa la finestra NLA Editor per comporre azioni e IPOs di oggetti in una animazione composita. Gli oggetti non devono essere necessariamente armature, ma negli esempi successivi useremo armature per le quali sono state create differenti azioni. Ogni oggetto può avere solo una animazione composita.
Il NLA Editor lavora in due differenti modi. Nel modo "Action" (singolo) solo l'attuale azione attiva viene riprodotta. Per riprodurre azioni combinate si usa il modo "NLA" (combinato).
[edit] Esempio introduttivo
Stiamo per iniziare con un facile esempio e costruiremo un "Braccio robotico" molto semplice con tre ossa (bones). (Image 1).
[edit] Creare le Azioni
Definiremo quattro differenti azioni per l'armatura.
- Abbassare il braccio rispetto alla sua posizione iniziale ("ArmDown")
- Riportare il braccio alla posizione iniziale ("ArmUp")
- Ruotarlo di 90 gradi in senso orario ("RotCW")
- Ruotarlo di 90 gradi in senso antiorario ("RotCCW")
Ognuna di queste azioni dovrebbe durare 20 fotogrammi. Dividi la finestr 3D e spostati nella finestra Action Editor.
Aggiungi quatro nuove azioni, e chiamale come illustrato in Image 2.
Queste quattro azioni voute verranno ora "riempite". Iniziamo con l'azione "ArmDown" (braccio giù). Seleziona quest'azione nell'Action Editor e metti l'armatura in Pose Mode. Seleziona le due ossa, premi I e scegli Rot nel menù InsertKey che apparirà. Spostati 20 frame più avanti (due volte Arrow Up) e posiziona l'armatura nella posizione finale desiderata. Again choose the two outer bones and insert the second IPO key (I->Rot) (Image 3).
Ora spostati all'azione "ArmUp" al frame 1. Il braccio dovrebbe trovarsi nella posizione finale. Salva le chiavi IPO per le due ossa esterne.
Adesso vai all'azione "ArmDown". Il braccio si trova nella sua posizione iniziale. Copiane la posa (Menu >> Pose >> Copy Current Pose)
, vai all'azione "ArmUp", al frame 21. Inserisci la posa (Menu >> Pose >> Paste Pose) e salva le chiavi IPO.
La rotazione del braccio su se stesso sarà creata quasi allo stesso modo, ma utilizzeremo solo il primo osso per la rotazione, in modo che i movimenti di questo siano indipendenti dagli altri. Per prima cosa crea una rotazione di 90 gradi in senso orario, poi una rotazione di ritorno alla posizione di partenza.
Finora abbiamo definito le quattro azioni, adesso le combineremo nel NLA Editor.
[edit] NLA
Passa dalla finestra Action Editor al NLA Editor
. Il nome dell'oggetto con un'azione associata compare sul lato sinistro della finestra.
Ora bisogna aggiungere le cosiddette "Strisce". Queste strisce sono azioni, che possono essere combinate nel NLA editor. Sposta il puntatore del mouse sul nome dell'oggetto e premi Shift A. Se ricevi il messaggio Object has not an Action il mouse si trova probabilmete su una parte vuota della finestra.
Seleziona un'azione nella finestra popup Add Action. Ripeti il procedimento per tutte e quattro le azioni. Solo una delle azioni può essere attiva (ed è indicata da un punto nero), e solo i simboli Ipo (a forma di diamante) dell'azione attiva sono visibili (Immagine 5). É possibile selezionare e spostare le azioni con i metodi convenzionali. Posiziona le azioni come nell'Immagine 6. Tieni Ctrl premuto mentre le sposti, per attivare lo snap ai frame. Usa Shift S (Snap to Frame) per sincronizzare una striscia con il frame successivo.
Avvia l'animazione (Shift Alt A). Si può notare che solo l'azione attiva viene eseguita. Clicca sul bottone evidenziato in giallo nell'Immagine 6 (anche se non sembra un bottone, lo è). Il bottone ora mostra l'icona del NLA Editor. Ora sei in modalità NLA.
Le strisce sono considerate dall'alto al basso, ciò significa che i canali specificati nelle ultime strisce subiranno l'influenza delle strisce precedenti (as long as the same IPOs are affected). Le strisce nell'Immagine 6 non sono sovrapposte, quindi le quattro azioni sono eseguite sequenzialmente. É possibile spostare le strisce per ottenere movimenti compositi, nonchè copiare le strisce, per le azioni ripetute. Si possono inoltre scalare le strisce, mescolarle e aggiungere movimenti. Si può mantenere la posizione finale dell'oggetto anche una volta teminata la striscia.
Le proprietà di una striscia vengono cambiate tramite il pannello Transform Properties , richiamabile con N. Attiva il bottone Hold per ogni striscia, in modo da mantenere la posizione finale per ogni azione. Vai alla sezione Reference per le altre opzioni.
Nell' Immagine 7 si può vedere un'azione composita. Osserva l'icona NLA davanti ai nomi degmi oggetti. Of cause you could achieve the result in Image 8 on other ways, but you have greater flexibility and I think it's more intuitive not to work with positions but with complex movements. Data l'impossibilità di renderizzare le ossa nella versione 2.41, sono stati utilizzati oggetti imparentati per l'animazioni nell' Immagine 8.
[edit] Reference
You can display the NLA Editor window with Shift Ctrl F12. In the NLA Editor you see a representation of all Objects with either Actions or Ipos. On a per Object basis, you can add "Action Strips" with Shift A, adding as many Actions as you like, allowing you to mix different Actions and edit their timing and relationships non-destructively. Each Object can have only one active Action, which is displayed in the Action Editor. This active Action is the one which will receive any new keys you insert, and whose keys you can directly edit.
The actions may be created for the same or for other objects. The strips are inserted in the current frame. The last added strip is activ, it is drawn in yellow. Clicking on a Strip itself or on the left-hand bars will set a strip to being the active Action.
You add new Ipo-Keys to the active Action, you can directly edit these Keys (delete, move). The objects you select in the NLA window are selected also in the 3D window.
Ipos for objects - also for armature objects - can be converted to actions in the Ipo window.
[edit] Display
- Only if an object has Ipos, an action or NLA strips it is shown in the NLA editor window. The top-most horizontal bar for an individual object shows the Object's name to the left, and any "keyblocks" (the diamonds that represent keyframes) for the Object Ipo on the right. (Image 9, the "Lamp" has no action only object Ipos).
- Below the Object bar the active Action is shown, and the "keyblocks" for the Action Ipos.
- Finally, the "Action Strips" are drawn. The active Action Strip is indicated with a dot icon. Clicking on a Strip itself or on the left-hand bars will set a strip to being the active Action.
- The button to the immediate left of the Object name toggles Blender between evaluating the entire NLA and displaying the results in the 3D window, or only evaluating the active Action (Image 9, the camera is in "Action" mode, the armatures are in "NLA" mode).
[edit] Strip Menu / Transform Properties Panel
You edit the properties of the Strips and Keys via the Strip menue or via the Transform Properties panel, that is opened as usual with N.
- Move Up/Move Down: In "NLA" mode the strips are evaluated top to bottom. Channels specified in strips later in the list override channels specified in earlier strips. With Page Up resp. Page Down you change the order of the strips.
- Delete: To delete a Strp or a Key. Deleting a Strip affects only the NLA editor, if you delete a key the position is permanently gone.
- Duplicate: Copies Strip or Ipo.
- Snap to Frame: Snaps start and end of the strip resp. the selected Ipos to frames.
- Reset Strip Size: Resets the size of the Strip in NLA to match the chosen range of frames from Action.
- Reset Action Start/End: Resets the chosen range of Action frames to include all frame in the Action (this is only necessary if you are not using the new Locked Strip Length feature, and is useful for fixing older files or if you have "lost your place" when adding or subtracting frames from Actions).
- Grab/Move: Moves the strip horizontal. With Ctrl you move in complete frames.
- Scale: The pivot-"point" for scaling is the current frame. By setting the frame you can select whether the end, the beginning or a point in the middle of the strip shall keep its position.
- Timeline Range: The first and last fame of the strip in the timeline. The strip length is independent from the length of the action.
- Locked Strip Length: By setting the strips to Locked, NLA will alway keep strip length up-to-date with your Action edits so that all keys are included. Locked mode is the new default, as it is far superior to the old behavior, but older files will have to be updated manually for this feature to work. If you release this lock, you can choose only a part of the action to be included in the strip. Action End may not be smaller than Action Start, so you can't reverse an action in the NLA editor.
- Blending: The number of frames of transition to generate between this Action and the one before it in the Action strip list.
- Repeat: The number of times the Action range should repeat. Not compatible with Use Path setting.
- Hold: If this is enabled, the last frame of the Action will be displayed forever, unless it is overridden by another Action. Otherwise the armature will revert to its rest position.
- Add: Specifies that the transformations in this strip should add to any existing animation data, instead of overwriting it.
- Stride Support: These option will be covered further below.
[edit] Stride Support
The Stride Support solves an otherwise complicated synchronisation problem. If a body moves a certain distance by an action, when has the next action to take place, so that action and movement are always in sync?
Two simple examples:
- A wheel rolling on a plane covers a certain distance with each revolution.
- With each step you cover a certain distance.
It's easy to synchronise a single movement, but what if the object has to become faster or slower along it's path? There is a second problem with a stride, because each foot stays a certain time at the floor. To solve the first problem we will use a Stride Path, for the second we have to use an additional Stride Bone. Therefore we will beginn with the wheel problem, because it is simpler to solve. The more simple way without a Stride Bone may also be used, when the contact with the ground is very short - or if one can't see it.
[edit] Example 1: Stride Path
Start with a new scene, remove the cube. Change to sideview (Num-1). Add an armature, one bone is enough. Change to Pose Mode and select the bone.
Split the 3D-window, change to the Action Editor. Add a new action, call it "RotCW". Add five IPOs. The first IPO in starting position (I->Rot), and than rotated by 90 degrees clockwise respectively. This action is very simple but can show everything important.
Change to topview in the 3d-window (Num-7). Add a path with Space>>Add>>Curve>>Path. We could use a "Bezier" or a "Nurbs" curve as well, but than we would have to add a Speed IPO curve later. The Path already posesses a Speed curve, therefore we use it here.
The path is in edit mode, change to object mode (Tab). Select the armature ( RMB
). The armature is still in pose mode, change to object mode.
Select the path with Shift RMB
, Ctrl P to parent the armature to the path (a modifier doesn't work here). Select Follow Path. If you press Alt A in the 3D window, the bone rotates one time around itself and is moved along the path in 100 frames.
To symbolise the "Wheel" add a Circle with 8 vertices in side view, use a SubSurf modifier level 2, and scale the circle on a diameter of exactly two blender units. Change the armature to pose mode and parent the circle to the bone (Image 12). Now armature and circle move synchroniously.
Now (finally) to the Stride Path. The circle shall move exactly one perimeter along the path for every complete rotation. Seen from the "Stride path" point of view: repeat the action after the armature has moved the distance Stride along the path. The distance Stride has obviously to be the circle perimeter - after a complete rotation the circle is in it's starting position and the action has to be repeated.
If you have a circle with a known diameter it is easy to get the perimeter, it's simply (diameter * Pi), in this case (2 blender units * 3.142 = 6.284 blender units). We have to use this value for Stride. Change to the NLA editor, add the "RotCW" action for the armature. Switch to NLA mode. Select the just added "RotCW" action if it's not already selected, press N, the Transform Properties panel appears. Switch Stride Path to on and set the Stride value to "6.284" (Image 13).
Rotation and movement along the curve are now synchronised. Each 6.248 blender units movement along the path the circle has rotated one time around itself. Extrude the path in edit mode and fit it in it's desired shape. The "Wheel" begins slowly and stops slowly. To change the velocity along the path change to the IPO Curve Editor while the path is selected. Select IPO Type "Path". The Speed curve is (fortunately) not the velocity but the relative position along the path. Edit the Speed curve (Ctrl LMB
adds new points). The position along the path changes accordingly. The object stands still on horizontal sections, it moves fast on steep sections (Image 14). Rotation and movement along the path stay synchronised.
Usefull tips
|
The result: the "Wheel" follows the curve, all global movements of the "Wheel" can be changed with the curve (Image 15).
[edit] Example 2: Stride Bone
As you've seen in our first example, the armature object moves steadily along the path. If you want a bone to hold it's movement you have to define an opposite movement, that cancels out the movement of the armature object. To define this movement we'll use a Stride Bone. The total movement of the Stride Bone (in Blenderunits) from the first to its last Ipo defines the Stride Parameter, the total movement along the path for one action.
We're going to use a very simple example, which could be improved a lot for actual usage. But again - it shows everything that is necessary. A "foot" with "lower leg" shall hop first in place, and than begin to move foreward.
Setup:
- Open a new scene, remove the cube and change to sideview (Num-1). Add an armature, rotate the bone by 180°. Extrude the second bone 0.5 BU (Blenderunits) 90° to the right ("Foot"). Select the tip of the "Foot" bone and snap the cursor to the selection (Shift S->Cursor to Selection). Add a third bone (don't extrude) (Space->Add->Bone), this will become the IK-Solver. Rotate and scale this third bone as you see fit (Image 17).
- Rename the bones, the first bone gets the name "LowLeg", the second one "Foot", the third one "IK-Solver". Select the "IK-Solver" bone, then with Shift RMB
the "Foot". Ctrl I-> Add IK-Constraint. Our "Rig" is ready, now to posing.
Create poses:
- Change to Pose Mode. Split the 3D-Window, change to the Action Editor. Add a new action, call it "Hop".
- Create poses for the "LowLeg" and the "IK-Solver" bone. The "Foot" will be moved automatically. Create four unique poses (Image 18), insert the first pose again at the end (Image 20).
After all these preparations the Stride Bone will be added.
- Add a fourth bone in Edit mode, rename this bone to "Stride Root". The "Stride Root" bone has to point in the opposite direction of the armature movement. The exact absolut positioning along the X-Axis doesn't matter, but the relative movement has to be exact (Image 19).
- Change to Pose Mode and add poses for the stride bone to the action "Hop".
How the Stride Bone works
|
- We're going to synchronize the "Stride Root" bone with the tip of the "Foot" bone in the frames 1-11 and 51-61. Define following Location poses (I->Loc) for the stride bone:
- Frame 1: Startposition
- Frame 11: Startposition again
- Frame 51: The "Leg" object shall move between Frame 11 and Frame 51. Therefore we have to move the Stride Bone the equal distance in the direction of the movement. Move the Stride Bone one BU in the direction of the movement and add the next Ipo.
- Frame 61: Since the (tip of the) leg rests on the floor between frame 51 to 61, the Stride Bone has to stay in it's position. Add the last Ipo.
Insert the path:
- Change to Object Mode and to topview (Num-7).
- Space->Add->Curve->Path.
- Change to Object Mode, select the Armature in Object Mode und with Shift RMB
the path.
- Parent the Armature to the Curve (Ctrl P->Follow Path). If you press Alt A in the 3D-Window, the Armature follows the path.
The setup for the stride bone happens in the NLA Editor:
- Shift A->Add Action->Hop
- Change to NLA-Mode ( LMB
on the icon with the little man next to the armature name).
- N to open the Transform Properties Panel.
- Activate Stride Path, "Y" as axis for the Stride Bone.
- Insert the name to the Stride Bone in the respective field ("StrideRoot"), or select the "StrideRoot" bone in pose mode, and click in the Armature Bones panel the Stride Root button.
Press Alt A in the 3D-Window or Shift Alt A in the NLA Editor. The armature moves hopping along the path. By modifying the Speed-Ipo of the curve and the Ipos of the "Stride Bone" you can change the speed, direction and character of the movement, without changing the Ipos of the "Hop" action.
[edit] Change the movement by manipulating the Stride Bone
Select a bone in Pose Mode, press W and choose Calculate Paths to draw the path of the bone in the 3D-Window (Image 22).
The Speed-Ipo of the curve rules the velocity of the movement along the path. With a Stride Bone you can manipulate the distance of the stride and the general character of the movement. Select the Stride Bone in Pose Mode and change to the Ipo Curve Editor (Image 23). If you set LocY to 2, the jump is twice as far and needs twice the time, if you set LocY to 0.5 accordingly faster and shorter. See Blender Stride Tutorial for complete examples.
[edit] Summary
- Create an action in place for the armature.
- A Stride Path is a curve with a Speed-IPO, normally a Curve->Path object.
- The armatue object is parented to the curve in object mode, so that it will follow the curve. A Follow Path constraint does not work as a stride path.
- An object will be skinned as usual. After a certain distance in blenderunits the action shall be repeated. You have to measure (or calculate) that distance. Use this value for the parameter stride.
- The action is added in the NLA Editor window, the NLA Editor has to be in NLA mode.
- Turn on Stride Path for the action in the Transform Properties panel and fill in the Stride parameter.
- A Stride Bone allows for finer synchronisation of single bones with the objectmovement of the armature in total. You can "clamp" bones to their position, while the armatureobject moves along the path.
- The Stride Bone has not to be parented or otherwise fixed to the other bones, he only has to be part of the action.
[edit] Links
- NLA Editor, Releasenotes of v2.40
- Advanced Stride Support, Releasenotes of v2.40
- Walk-Cycle Tutorial (v2.41)
- The "old" Walk-Cycle Documentation (v2.31)
Redirects to fix
- Manual.it/PartX → Doc:IT/Manual/Physics






























![[]](/skins/blender/open.png)
