Download Animation State Machines: Sequencing Animations with States and Transitions and more Slides Computer Graphics and Animation in PDF only on Docsity! Animation State Machines
Ean 3 ay OE a! i: RY Ps : 5 ae
State Machines Blending is great for combining a few motions, but it does not address the issue of sequencing different animations over time For this, we will use a state machine We will define the state machine as a connected graph of states and transitions At any time, exactly one of the states is the current state Transitions are assumed to happen instantaneously Docsity.com Simple Jump State Machine Consider a simple state machine where a character jumps upon receiving a JUMP_PRESS message stand jump JUMP_PRESS Docsity.com More Complex Jump stand hop stand2crouch crouch floattakeoff land JUMP_PRESS NEAR_GROUND JUMP_RELEASE JUMP_RELEASE Docsity.com State Machine (Text Version) stand {JUMP_PRESS stand2crouch } stand2crouch { JUMP_RELEASE hop END crouch } crouch {JUMP_RELEASE takeoff } takeoff {END float } hop {END float } float {NEAR_GROUND land } land {END stand } Docsity.com Character Mover
Ean
ea
Character Mover When we want an interactive character to move around through a complex environment, we need something to be responsible for the overall placement of the character We call this the character mover We can think of the mover as a matrix that positions the character’s root Docsity.com Character Mover Usually, we think of the mover matrix as being on the ground right below the character’s center The mover sits perfectly still when the character isn’t moving and generally moves at a smooth constant rate as the character walks The character’s root translation would be animated relative to the mover Docsity.com Character Mover Sometimes, we want the character to do more complex moves, such as a dive roll to the right In this situation, we might want to explicitly animate what the mover should do This data can be written out with the animation and stored as additional channel data (3 translations, 3 rotations) These extra channels can be blended like any other channel, and then finally added to the mover when we pose the rig Docsity.com Project 3 Load an .anim file and play back a keyframed animation on a skinned character Extra Credit: Display the channel curve Simple channel editor Docsity.com Anim File animation { range [time_start] [time_end] numchannels [num] channel { extrapolate [extrap_in] [extrap_out] keys [numkeys] { [time] [value] [tangent_in] [tangent_out] … } } channel … } Docsity.com