Messiah
ABC
Revised 7/2/00
The goal of this tutotial is to take the
long route to creating an animation of a tube forming itself into the
letters, A, B and C using Project Messiah, an animation plugin for Lightwave
3D. The focus is on gaining familiarity with the P:M toolset,
not the creation of this particular animation. The idea being
that you need to walk before you can run. This goes into quite
a bit of detail, and I hope it is accurate and useful, but I don't warrantee
it in any way, shape, or form.
Please note that some of the screen grabs
were modified a bit to better fit on the page.
There are many ways to accomplish things
in Messiah (in life in general). If anyone has suggestions to
improve efficiency or an idea for an additional section which would
provide further insight into the P:M toolset, let me know (mitch@thepixelfarm.com)
and I'll consider adding it (especially if you help write it).
I hope others will find this useful, but
in order to keep authoring time down, the presentation is very straightforward.
Read the steps, read the notes. The format is simple: Below
each picture are the steps and notes associated with it. Note
that "F" denotes a frame number or range. So F3 means
Frame 3 of the animation, and F-3 means Frame -3 of the animation. F0-10
refers to the range of frames from Frame 0 to Frame 10, inclusive of
Frame 0 and Frame 10. I used a small type in laying this out,
if need be you can enlarge the type using options in your browser.
Written with heartfelt thanks to everyone
who has contributed to the Project Messiah mailing list. The discussions
there have pointed me in the direction of which stuff to focus on learning
first.
Important Note:
After posting this tutorial, Dan Milling pointed out to me that it is
a bad habit to name an item using a text string which could be considered
a mathmatical expression. This can lead to problems if you then
use this item in an expression, because the name of the item will be
then be evaluated mathmatically which will result in P:M not finding
the item. So, for example, in this tutorial I have named an expression
CBFM-1. If I had then wanted to reference that expression in other
expressions, P:M would attempt to subtract 1 from something named CBFM,
which it would not find. The expression would then fail. So
be aware of this. Naming the expressions with an underscore (i.e.
CBFM_1) would avoid the problem. Thanks Dan.
Ingredients:
(If they open in your browser, right click and choose to "Save
Link As..."or some equivalent command to save them directly to
your computer).
Cylindrical Mesh Object
Messiah Scene File (This is the completed
project, you should start with a new Messiah project)
Topics Covered (not necessarily in this
order):
Adding Skeleton to mesh
Setup v. Keys mode
Creating keyframes w/skeleton
Selecting multiple objects
Moving Keyframes for multiple objects
Deleting Keyframes for multiple objects
Change Visiblity for multiple objects
Copying/Pasting Keyframes w/Motion Clips
Setting up the CycleBranchMorphFrame Expression
Playing with expressions a bit
Adding/Setting up a slider
Connecting the CycleBranchMorphFrame Expression to a slider
Misc Keyboard Shortcuts
|
|

STEP A: Add a Mesh
- Import a 12meter Cylinder (Click HERE
to get it) .
- Go to Effect Tab, select Cylinder in object list, Choose
Bone_Deform, Click Add Effect button.
Notes:
- Red outline around main window.
This means that the selected object (now the bone deform) is in
stup mode. For bones, setup mode is where you setup the
bones, i.e. The bone positions before they start deforming the
object.
It is not a keyframed state, rather, the starting position of
the bones in the skeleton.
- Use Cntl+Alt+drag to reposition the object in the orthogonal
views.
Suggestion:
- Print out the keyboard commands from the HTML Manual.
You'll learn a lot just having them as a reference.
|
|

STEP B: Add a Skelton, Pt.1
- Open the Animate Tab. You are still in setup
mode-note that the "Setup Subtab" is forward. Click
the "Keys Subtab" to see what happens when you go out
of setup mode. Go back to setup mode before proceeding.
Click "Add Child" to add first bone.
- Set Length of bone to 1. Move Child to Z = -6.
Notes:
- You now have a 1 meter bone positioned at the bottom
(Back, actually), of a 12 meter tube.
- The tube was laid out on the Z axis so the bones wouldn't
have to be rotated to align them to the tube object.
- With the main window active, use the escape key to
turn off the edit spheres (compare to previous screen grab).
|
|

STEP C: Add a Skelton, Pt. 2
- Click "Add Child" 11 more times.
Notes:
- You now have a 12 meter tube with twelve 1 meter bones
placed evenly along the length.
- F2 and F3 will toggle the file list window (or command
list window) between 2 sizes.
- "a" will center your object in the animation
window
|
|

STEP D: Get out of Setup Mode
- Select any bone in the heirarchy (bone deform effect),
then select the Keys Subtab. This takes the whole bone
heirarchy out of setup mode and ready to be animated.
Note how the red line is in the Animation Window has been changed to
blue.
Notes:
- Any individual objects (not sure if that includes all
possible item types) in the item list can be in setup mode or
keys mode. Use the Keys and Setup Subtabs of the Animate tab
to change this state.
- The bones have been set to invisible (The "N"
in the visibility column). The following modifiers make this easy
to do (Thanks to Ron Griswold for posting this):
- Holding down ctl while changing the visibility
of an object will change all of it's descendants as well.
- Holding down shift will get the current item and
all items on the same hierarchical level that are below the current
item in the list.
- You can also use a combination of ctl and shift,
if you use this combo on the first item in the list you will be
effecting all objects in the scene
|
|

STEP E: Create a Keyframed Shape
Lets add some keyframes. Grab the bar where the
frame numbers reside and drag it up to expose the graph editor. Go
to Frame 10 by dragging the yellow pointer to frame 10. Sculpt the
tube into the shape of the letter "A". Select a few of
the bones and use rotation, position, and scale keyframes to shape the
tube. Using more than just rotation will be useful in a later part
of this tutorial. Drag the yellow frame indicator between 0
and 10 to see your masterpiece in motion.
Notes:
- Caution: When editing keyframes in the Animaiton Window,
if you don't have the edit sphere displayed, you need to drag directly
on the object you want to modify. If you drag in the Animation
Window outside your object, the modifications will be applied to the
last modified keyframe.
- Use the "{}" to change the size of the edit
sphere.
- Use the arrow keys to select items in the object list.
- Use the "a" to zoom either the Animation
Window or the Graph Window to the current object or keyframes
- Use "0" to cycle Move, Rotate, Scale. Use
1-9, to select invidual channels. Just try'em out.
- Use "n" to get to the animation window.
- Use Cntrl + Right/Left arrow to jump to keyframes.
- Use the middle mouse button to select objects.
|
|

STEP F: Use a Motion Clip to copy a keyframe for
multiple objects.
MessiahABC05.fxs would
be the starting file for this steps F & G.
Next we'll go to F20 and sculpt the letter B, but we'll
take the long route. A useful procedure is to be able to copy keyframes
from a group of objects in a single step, in this case a heirarchy of
bones. There may be more than one way to do this in Messiah, but
one technique is to use a motion clip. Before we shape the
"B", let's reset the object to it's initial position by copying
the keyframes from F0 to F20.
Now watch this carefully, because it's VERY USEFUL.
- Activate the Edit Tab and choose the Motion Clip option
from the module sub tab (Shortcut: m).
- In the Create (i.e. Create Motion Clip) subtab, make
sure "selected objects" is the chosen in the popup menu and
"Record Descendents" is checked.
- Select the "Skeleton:Bone_Deform" effect,
"Record Descendents" will insure that all the keyframes in
the bones in the heirarchy will be copied into the Motion Clip.
- We are only copying 1 keyframe for all of the objects,
so set the in/out points of the graph editor to 0 and 1. Motion Clips
can be of any temporal length, but we only want to copy the keyframes
at frame 0, setting the in/out points controls this. If your current
keyframe indicator is not at F0, move it there. This is not necessary
at this point, but it will be in an upcoming step.
- Click the Copy button, note how the message in the
animation window says "Motion Clip: 13 Objects". Cool.
We just copied all the keyframes from the Skeleton:Bone_Deform
and 12 bones.
- Save your file, and lets play around with this a bit
more before we move on. Here we have a function which should prove
to be very useful, so lets get comfortable with it. Consider that
the Motion Clip is a motion clipboard. It stores one motion at
a time, just as the Operating System Clipboard stores one piece of digital
information. Select the Camera from the objects list and click
the copy button. Note the message in the Animation Window. Use
the shift key to select the Camera and the Cylinder Object, then click
copy - observe the message. Try one of the bones. Try 2
of the bones. Turn off the "Record Descendents" button
and try a few more. Use the "Control" key to select
objects which are not next to each other. You get the picture...
Okay. So make sure "Record Descendents" is on
and select either the Skeleton:Bone_Deform or the topmost bone to which
you have assigned a keyframe (probably Bone_1) and use the copy button
to create a motion clip.
Notes:
- The Motion Clips function could be used to copy and
save motions from multiple objects as well. It has plenty of other
bells and whistles that we haven't even touched on here. Read
about it in the manual.
- There are several ways to set the In/Out points, consult
the manual
|
|

STEP G: Use a Motion Clip to paste a keyframe for
multiple objects.
Now this is a bit tricky, so be patient and be prepared
to experiment a bit to become familiar.
- Activate the Paste Tab of the motion clip module
- Click "Perform Match" and note the message
in the animation window says "13 Objects Matched". The item
list shows that for each bone, it has found a corresponding object which
matches and will receive a keyframe during the paste.
- Set the offset to 20, Frames to 1.
- Click "Reset Clip Range"
- Move the out point in the motion graph past F20. It
appears that P:M won't paste keys outside the active range.
- Click Paste.
- Drag the current frame cursor between FF0-20 or hit
the play button. Your tube should now fold into an "A"
from FF0-10 and unfold from FF11-20. Cool.
- Again, lets consider what is going on here. P:M
has stored our Motion Clip and its still there. There are other
things we could do with it at this point:
- If it were more than one KF in length,
we could stretch it during the paste.
- We can paste it in more than one place.
- We could save it in a library and use it elsewhere.
- We can use other functions in P:M and when we return,
the Motion Clip will still be there.
- ....
- Save your file and try this:
Note the new bordered rectangle which shows up in the Motion Graph during
the paste procedure. This controls the pasting of the motion.
- Grab the green triangle on this box and
drag it approximately to F15. Look at the offset box to when you
finish dragging to see where it really is. (The red handle
on the box will resize it, which I think will tell P:M to stretch
the motion - this wouldn't work in our case because we only have
one KF).
- Click the "Quantize Keys" box, this will
tell P:M to paste the KF on a whole number Frame (as opposed to
a fractional frame). Click Paste again. Click the play
button.
- Click on your new keyframe. The current time
marker should jump to it (Jumping to selected keys can be set in
the "Keyframe Editing" module of the Edit Tab). Select
your new keyframe by dragging w/LMB in Motion Graph. The message
"1 Key Selected" should appear in the Animation Window.
Press the delete button to bring up the "Delete Key"
dialogue. The current Frame Number should be listed in the
"Delete Key" dialogue box, if you need to enter a different
number, be sure to press the tab key after entering it, select "All
objects", and click ok.
- If you have trouble deleting the keyframe
for all objects, go to the animate tab ("n"), click on
the keyframe to select it and make sure the current time jumps to
it, then press the delete key and choose the "All Objects"
option. This should also work if you want to get rid of a
fractional KF
Suggestion:
- Whenever you want to test out a new feature, put away
your complex setup of meshes and bones and create a simple scene with
a few spheres which have very simple keyframed motion. Test out
the copying, pasting, stretching, shrinking, etc. w/a simple scene to
learn how the functions work.
|
|

Step H. Create a new Shapes at F20 and F30.
- We didnt really keep track of which bones we added
keyframes to when we shaped our letter "A"at F10. But
when we shape our letter "B", which is a much more complicated
shape than "A", we will probably need to add a keyframe to
every bone. You don't really need to know which bones have keyframes
at F10, but if you did want to know, you could use the arrow key to
successively select each bone in the list while at the same time watching
the motion graph. You would see the keyframes appear for the objects
that have them. What we do want to do at this point is create
a keyframe for every bone at F10. This will insure that our cylinder
will hold its shape at that frame. If we didn't do this, then
the bones which didn't have a KF at F10 would move smoothly from their
settings at F0 to the settings we are going to add at F20. This
would probably ruin our "A" shape. To create a KF for
all the bones at F10, move the current frame marker to F10. Select bone_1
and press enter. In the Create Key Dialoge, choose the "Current
Item and Descendants" option.
- Now go to F20 and shape a "B". Don't
worry if it isn't beautiful, that's not the point of this excercise.
Click the Play Button. It may not be a T-Rex catching a
Teradactlyl in mid-air, but it should be interesting...
- Use the techniques discussed so far to create the shape
of the letter "C" at F30. Play and watch the magic.
- For purposes of this excercise, we will want a keyframe
for each bone when we form the letters, so select bone_1, go to frame
20 and press enter to open the "Create Key" dialog. Select
the "Heirarchy" option. Do the same at F30.
|
|

Step I. So what's all this stuff about CycleMorphBranchFrame
and Sliders?
MessiahABC07.fxs
would be the starting file for this Step I&J.
So what if these Keyframes were really complex poses that
we had spent painstaking hours to compose? We'd want to get maximum
flexibility out of timing them, blending them, repeating them, etc. The
CycleMorphBranchFrame (CBMF) expression allows us to reference the pose
at a given frame. Attaching CBMF to a slider or a complex expression
adds greater control and flexibility. Let's take a look.
- Start by moving our keyframes out of the way. Just
as copying keyframes simultaneously from multiple objects is very useful,
so is moving them. P:M lets you use negative keyframes, so lets
move our 3 poses to keys -1, -2, and -3. Go to F10 and select
the "A" keyframe. Select Bone_1 in the item list and
press the "\" Backslash key to bring up the Move Dialog. The
"Move Key At" field should be set to your current frame (10).
Enter "-1" in the "To" field and be
sure to press tab so the number is entered. Choose the "Current
Item and Descendents" option. Your keyframe should be moved
to F-1. Repeat this procedure, moving the "B" keyframes
at F20 to F-2, and the "C" KeyFrames at F30 to F-3. The
navigation arrow next to the "Center" button on the Motion
Graph will allow you to scroll the Motion Graph so you can see the Keframe
values at the negative Frames. Click on each of these frames to
devance the cursor there and make sure the shapes are correct. If
some of your bones in the original poses weren't keyframed, these keyframes
might be off...
|
Step J. Setting up the expression.
- Go to the Command Tab and click the "New
Expression" button in the Expression Subtab. In the
name field type CBFM -1 or whatever you want to name this first expression.
This first expression will use the motion of the skeleton at F-1
and morph to it over 10FF. Don' worry about the other settings
on this tab at this time.
- Select the Functions Subtab. This screen
makes it easy to setup the expression. From the pop out menu choose
CycleBranchMorphFrame. This function has 5 parameters, and they
are quite simple:
- Source object
- Target object
- Motion Channels. (In this case we've selected all
the motion, but note the other options.)
- Frame number from which to copy the motion.
- Float = Morph amount. This can be any legal
mathmatical expression. Even a simple number will work. When
the float is equal to one, the Target object will receive 100% of
the effect.
- For starters, select the options as listed in the picture
above, but instead of NOW/10 in field 5, just type in a "1"
(No Quotes).
- Right click next to the pop out menu and the expression
will be copied into the Command List and into the "Exp" field.
- Drag the Current frame marker around the Motion Graph
and you should see the "A" shape all the time. The skeleton
is now being controlled by the expression, which is set to look at the
motion at F-1, and to Morph to 100% of the value at F-1 because the
Float (or Morph amount) is always equal to 1.
- The Text String NOW (uppercase is important) tells
P:M to use the value of the current frame in the expression. For example,
NOW would be equal to. 1,2, and 3 at F1, F2 and F3 respectively. The
Mathmatical Expression NOW/10 would thus be equal to 1/10, 2/10, 3/10,
etc. as the animation proceeds forward from F0. When it reaches
F10, NOW/10 will be equal to 10/10 or 1, so our Float will be equal
to 100% at that frame. You can change the expression by editing
the text directly in the "Exp" field. Change the value
of the float from 1 to NOW/10. Press enter to change the expression
in the Command List. Drag the Current Time Marker around.
Note what happens after F10 and before F0. The motion of
the skeleton is added to itself (or subtracted on the negative side
of the Motion Graph)... or something like that. Anyway, what is
important is that you are controlling the skeleton with a mathematcal
expression.
- Go back to the Expression Tab and hit the "Copy
Expression" tab. A copy of CBFM-1 is added to the Command
List. In the "Name" field, change CBFM-1 to CBFM-2 and
hit enter.
- Go back to the Functions tab, select CBFM-2, and in
the "Exp" field, change the frame field to -2, and the float
to 1. The expression will be:
CycleBranchMorphFrame(Skeleton,Skeleton,motion,-2,1). You could
even copy it from this web page and paste it in. Now we have setup
conflicting messages (2 expressions which take total control of the
motion of the skeleton), how do you think P:M will choose? Drag
the Current Frame marker to see. All we see is the "B"
shape. Does it choose the the bottomost expression? No.
It evaluates all the expressions from top to bottom, and in this case,
the value of the bottom expression totally replaces that of the top
one. Want proof?
- Turn off the CBFM-2 expression by clicking the switch
next to the IK cell in the Command List. Drag the Current Frame
Marker around. CBFM-1 rules!
- Lets have a bit more fun. Set the inpoint to
0, outpoint to 100. Hit play. The tube is winding itself
into a tangled mess. Cool. Without turning off the playback, click
the switch next to the CBFM-2 expression to turn it back on. P:M
immediately updates itself and the tube assumes the "B" shape.
Switch CBFM-2 off and select CBFM-1, the expression for CBFM-1
will appear in the "Exp" field. Add another "0"
to the float in the CBFM-1 expression so that the float is equal to
NOW/100, hit enter. The tube now morphs into the "A"
shape in 100 frames. Don't turn off the playback yet. Turn
CBFM-2 back on. In the Command List, click on the cell containing
"IK" next to CBFM-1, it changes so that its expression will
be evaluated after IK.

Now it morphs from the "B" shape to the "A". I'm
not really sure why this happens, but its pretty cool. Experiment
a bit more (try changing the float in CBFM-2 to .5), then take
a break.
Notes:
- You can do lots of stuff during playback in P:M.
|
|
Step K. Adding a Slider

Slider before hiding and renaming channels

Slider
after hiding and renaming channels
- Go to the File Tab and add a slider using the
"Add" Subtab. Rename the slider to "LetterShape"
using the "Name" Subtab. Note that when the slider
is selected, it appears in the Animation Window. Go to the Animate
tab, and with the LetterShape Slider selected, right click on
the colored boxes next to channels 4, 5, and 6. This will turn
off the display of those channels in the Animation Window.
Rename the xpos channel to A, ypos to B, and zpos to C. Note that
the slider has a drag box and a resize box.
Notes:
- If the slider disappears while you're working,
go to the animate tab and select it from the item list.
|
|

Step L. Setup the sliders to control the animation
- Go to the Command Taband turn off CBMF-2.
Activate the Functions Subtab . Select CBMF-1
and change the float to [LetterShape:xpos] so that the expression reads:
CycleBranchMorphFrame(Skeleton,Skeleton,motion,-1,[LetterShape:xpos])
This will cause the value of the float for CBMF-1 to be obtained from
the xpos channel of the LetterShape Slider. Note that
even though we renamed the xpos of the LetterShape Slider to
"A", you still need to call it by it's default channel name
(in this case, xpos) in the expression . Set the current frame
to 0 and drag the slider "A" back and forth. Observe how the
slider now controls the tube changing into shape "A". Set
it to 0. Change the outpoint and the current Frame to F10 and
drag the slider "A" to 1 (all the way to the right). It
will create a keyframe for the slider. Hit play. The keyframing
of the "A" channel of the slider now controls the bending
of the object into the "A" shape.
- Turn CBMF-2 back on and select it. Change the
float to [LetterShape:ypos] so that the expression reads:
CycleBranchMorphFrame(Skeleton,Skeleton,motion,-2,[LetterShape:ypos]).
This will cause the value of the float for CBMF-2 to be obtained from
the ypos channel of the LetterShape Slider (which we have renamed
to B).
Just as before, the shape of the tube is controlled by both expressions,
but now the float in both expressions is controlled by a slider. At
each frame CBMF-1 is evaluated first, which bends the tube to some percentage
of the "A" shape, then CBMF-2 is evaluated. CBMF-2
starts where CBMF-1 left off, which is some percent of the "A"
shape.
- Setup a simple animation to bend from "A"
to "B". Go to the Animate Tab, expand the LetterShape
Slider in the item list and select "B". Go to F10
and hit enter. This will create a keyframe for "B" with
the value of 0. We don't want the tube to start bending into the
"B" shape until it has finished bending into "A".
By making B = 0, the float for CBMF-2 will also be 0. Click
the Linear Button for linear interpolation. Change
the outpoint and the current Frame to F20 and drag the slider "B"
to 1 (all the way to the right). It will create a keyframe for
the slider. Hit play. The tube bends to the "A"shape
from F0-10, then to B from F10-20.
Quick reminder:
Slider B=0 from F0-10, so it causes CBMF-2 to equal 0 during those frames.
Slider A=1 from F10 on, so as the expressions are evaluated from F10
on, the tube will be bent all the way to the "A" first.
|
|

Step L. Finish the animation, play around a bit
more, Go start your masterpiece.
- Go back to the Expression SubTab of the Command
Tab and select CBMF-1. Use the Copy Exp button to make
a copy and rename it to CBMF-3.
- Activate the Functions Subtab . Select
CBMF-3. Change the Frame number to -3, and change the float to
[LetterShape:zpos] so that the expression reads:
CycleBranchMorphFrame(Skeleton,Skeleton,motion,-3,[LetterShape:zpos])
This will cause the value of the float for CBMF-3 to
be obtained from the zpos channel of the LetterShape Slider (which
we have renamed to C)
This adds a third expression which also controls the shape of the
tube. Based on our previous setup and discussion of expressions
we know:
- The expression CBMF-3 will bend the skeleton
to the shape at F-3, which we setup as a "C" shape.
- CBMF-3 will be evaluated after the other 2 because
it is at the bottom of the list.
- The value of the float for CBMF-3 will be obtained
from the slider C.
- Add a bend from "B" to "C". Go
to the Animate Tab, expand the LetterShape Slider in the item
list and select "C". Go to F20 and hit enter. This
will create a keyframe for "C" with the value of 0. We
don't want the tube to start bending into the "C" shape until
it has finished bending into "B". By making C = 0, the
float for CBMF-3 will also be 0. Click the Linear Button
for linear interpolation. Change the outpoint and the current
Frame to F30 and drag the slider "C" to 1 (all the way to
the right). It will create a keyframe for the slider. Hit
play. The tube bends to the "A"shape from F0-10, then
to B from F10-20, then to C from F20-30.
- Okay, we're done, we've explored some of the basics.
Before you go back to working on that masterpiece, try one more
goofy thing. With the use of expressions, math can become another
experimental tool, just like a photoshop filter. If your so inclined,
you can play with it. Delete all your expressions and slider keyframes.
The best way I've found to delete multiple keyframes from multiple
objects is to use the motion clips panel ("m"). Set
the in/out points to include the keyframes you want to eliminate. In
the Create Subtab, , select the object (in this case the slider),
then click the cut button. Go to the Command Tab, create a new
expression and try this (copy and paste):
CycleBranchMorphFrame(Skeleton,Skeleton,motion,-2,([LetterShape:ypos]+[LetterShape:xpos])*(1/atan([LetterShape:zpos])))
Then move the sliders around and watch the tube twist. What we
have is a complex mathmatical equation being used to control the combination
of the 3 Keyframed states. It is developed by goofing around.
It doesn't have to make sense, it just has to look cool.
Have fun.
|