Saturday, July 16, 2011

Walk Cycle Train

A lot of the Flash animation on the internet consists of characters blinking whilst the camera pans or zooms Ken Morse style. I can sympathise – the mere thought thought of, for instance, producing a walk cycle for an animated character can be really terrifying.

Indeed, I have a couple of projects on the back burner that I’ve put off for just that reason – they would require me producing an animated walk cycle and I really didn't know where to start.

Sammy The Chamois

I remember producing a walk cycle for a Flash game called Sammy The Chamois from Alan Scragg's drawings. The walk cycle I produced was ridiculous and broke every known rule of anatomy and physics. Scraggie said he loved the way I’d broken all the rules in Sammy’s walk – I was too ashamed to admit that was because I didn't know what the rules were!

However playing with Synfig Studio gave me a new impetus to think about animation again, and I started searching for walk cycles on the internet.

Dermot O’Connor’s website

I was lucky enough to come across a brilliant web tutorial in Flash by the Irish animator Dermot O’Connor. Dermot explains, over four videos, how to produce the classic Preston Blair animated walk cycle in Flash in the most clear and concise way imaginable. If you have ever been interested in animation I recommend that you look at them.

Having looked through these tutorials, I thought it would be a good exercise to produce Dermot’s rig in Synfig Studio and try animating the character in Synfig Studio instead of Flash. The term “rig” is a rather pretentious term for what is basically the digital version of a paper puppet jointed with brass paper fasteners.

Dermot’s Rig In Synfig Studio

Producing the rig in Synfig Studio was very straightforward. I simply traced Dermot’s drawing using Bline layers (a Bline layer is a layer made up of Bézier curves). The only tricky thing was getting the centres of rotation in the correct position. In Synfig Studio each Bline’s origin (and hence its centre of rotation) is the centre of the screen. That means you need to trace the shape, move it to somewhere near the centre of the screen to get the centre of rotation correct, and then move it back into position.

This became even more fiddly when I created Paste Canvas layers (what would be nested symbols in Flash) as you had to do a lot of mucking about to get the origin points correct. However, the great thing about Paste Canvas layers is that is completely explicit if a layer has other layers nested inside of it. That meant I didn't need to use Dermot’s asterisk convention to denote nesting.

Rotation Layers

The other main difference between a Synfig Studio rig and a Flash rig is that the rotation is provided by a rotation layer, so they had to be added to the rig amongst the other layers.

The bright orange points are “linked”

For the arms and legs, I linked the two common nodes together so I could change the shape of the arms and legs in exactly the same way as Dermot could on his Flash rig.

Once the rig was set up, I could start animating. This was much easier in Synfig Studio than it would have been in Flash. The great thing about Synfig Studio was that I didn’t have to worry about shape hints for shape tweening. I didn’t have to decide whether I wanted a shape tween or a motion tween. I didn’t have to worry about creating new time-lines for nested layers and I could name my key-frames with meaningful labels rather than abbreviations such as “c” for “contact”, and then jump to them by clicking on the JMP in the layers panel.

My key-frames panel

The main disadvantage of Synfig Studio over Flash for animating is the lack of an outline mode. This meant that you have to do more layer hiding to animate the left hand leg and arm than you would in Flash.

There were a couple of other niggles in Synfig Studio – firstly when moving multiple layers you had to make sure the canvas window has the focus before using the arrow keys. This became very annoying until I learnt to do it instinctively. Secondly, it would be great if there was a visual indication of whether a node has merged or split tangents as there is in Inkscape.

This is what I did in ten minutes in Synfig Studio – it would have taken me a lot longer to achieve in Flash:

The walk cycle so far…

It's not finished, as the arms are still very mechanical and I haven't put the bend in on the feet. However thanks to Dermot I now have the both the confidence and the knowledge to try and working with my own projects either in Flash or Synfig Studio.

You can download the Synfig Studio rig I made from the Synfig Studio forum here.

4 comments:

Carlos said...

Great post!
You wrote:
The main disadvantage of Synfig Studio over Flash for animating is the lack of an outline mode. This meant that you have to do more layer hiding to animated the left hand leg and arm than you would in Flash.

Can you develop that concept? I don't understand it properly maybe due to my English or my inexperience with Flash.
Thanks!

Carlos said...

It was my English! I understand what you mean. It would be a good feature to add to Synfig Studio.

Carlos said...

Sorry for this third post but Synfig Studio has one feature that can supply the outline mode: Groups. You can add scattered layers into groups and select all them with a double click on the group, even if the layers are hidden (any layer). After that you can edit it normally. Groups can be nested allowing select only parts of the rig or all the rig chain (((forearm ((arm (hand)))

Unknown said...

@Carlos No, that's not quite what I mean by outline mode.

What I would like is to be able to see selected layers as just thin outlines with no fills, as you can in Flash. In Flash you can also chose what colour each layer's outline will be.

Dermot uses this capability of Flash to good effect in his videos - he doesn't have to hide layers as often as you do in Synfig, as he can see through them.

It has the added benefit of speeding up rendering of the Canvas whilst you are working.

Inkscape also has an outline mode, but all the outlines are black on white, and it's all the layers or nothing, which isn't as useful for animation.