Motion Capture & Simulation

Similar documents
Computer Animation and Visualisation. Lecture 3. Motion capture and physically-based animation of characters

Lecture VI: Constraints and Controllers

Human body animation. Computer Animation. Human Body Animation. Skeletal Animation

Animation. Computer Graphics COMP 770 (236) Spring Instructor: Brandon Lloyd 4/23/07 1

animation projects in digital art animation 2009 fabio pellacini 1

Last Time? Inverse Kinematics. Today. Keyframing. Physically-Based Animation. Procedural Animation

Lecture VI: Constraints and Controllers. Parts Based on Erin Catto s Box2D Tutorial

COMP 175 COMPUTER GRAPHICS. Lecture 10: Animation. COMP 175: Computer Graphics March 12, Erik Anderson 08 Animation

CS 231. Inverse Kinematics Intro to Motion Capture

Last Time? Animation, Motion Capture, & Inverse Kinematics. Today. Keyframing. Physically-Based Animation. Procedural Animation

Articulated Characters

Controlling Reactive, Motion Capture-driven Simulated Characters

CS 231. Inverse Kinematics Intro to Motion Capture. 3D characters. Representation. 1) Skeleton Origin (root) Joint centers/ bones lengths

Last Time? Animation, Motion Capture, & Inverse Kinematics. Today. Keyframing. Physically-Based Animation. Procedural Animation

Character Animation 1

Animation Lecture 10 Slide Fall 2003

Simulation. x i. x i+1. degrees of freedom equations of motion. Newtonian laws gravity. ground contact forces

Computer Animation. Algorithms and Techniques. z< MORGAN KAUFMANN PUBLISHERS. Rick Parent Ohio State University AN IMPRINT OF ELSEVIER SCIENCE

Manipulator trajectory planning

Robots are built to accomplish complex and difficult tasks that require highly non-linear motions.

Homework 2 Questions? Animation, Motion Capture, & Inverse Kinematics. Velocity Interpolation. Handing Free Surface with MAC

Character Animation. Presented by: Pam Chow

Lesson 1: Introduction to Pro/MECHANICA Motion

A simple example. Assume we want to find the change in the rotation angles to get the end effector to G. Effect of changing s

Animations. Hakan Bilen University of Edinburgh. Computer Graphics Fall Some slides are courtesy of Steve Marschner and Kavita Bala

Applications. Systems. Motion capture pipeline. Biomechanical analysis. Graphics research

ROBOTICS 01PEEQW. Basilio Bona DAUIN Politecnico di Torino

Animation. Itinerary Computer Graphics Lecture 22

Animation. Itinerary. What is Animation? What is Animation? Animation Methods. Modeling vs. Animation Computer Graphics Lecture 22

CS770/870 Spring 2017 Animation Basics

CS770/870 Spring 2017 Animation Basics

To Do. History of Computer Animation. These Lectures. 2D and 3D Animation. Computer Animation. Foundations of Computer Graphics (Spring 2010)

Animation. CS 465 Lecture 22

Applications. Human and animal motion Robotics control Hair Plants Molecular motion

Data-driven Approaches to Simulation (Motion Capture)

Announcements: Quiz. Animation, Motion Capture, & Inverse Kinematics. Last Time? Today: How do we Animate? Keyframing. Procedural Animation

Animation, Motion Capture, & Inverse Kinematics. Announcements: Quiz

Computer Animation Fundamentals. Animation Methods Keyframing Interpolation Kinematics Inverse Kinematics

animation computer graphics animation 2009 fabio pellacini 1 animation shape specification as a function of time

animation computer graphics animation 2009 fabio pellacini 1

Motion Synthesis and Editing. Yisheng Chen

Cloth Animation. CENG 732 Computer Animation. Simple Draping. Simple Draping. Simple Draping. Simple Draping

Overview. Animation is a big topic We will concentrate on character animation as is used in many games today. humans, animals, monsters, robots, etc.

Research Subject. Dynamics Computation and Behavior Capture of Human Figures (Nakamura Group)

Character Animation COS 426

Mapping optical motion capture data to skeletal motion using a physical model

ROSE-HULMAN INSTITUTE OF TECHNOLOGY

Simulation in Computer Graphics. Deformable Objects. Matthias Teschner. Computer Science Department University of Freiburg

1 Trajectories. Class Notes, Trajectory Planning, COMS4733. Figure 1: Robot control system.

PSE Game Physics. Session (3) Springs, Ropes, Linear Momentum and Rotations. Oliver Meister, Roland Wittmann

John Hsu Nate Koenig ROSCon 2012

CS 231. Motion Capture Data I. The Pipeline. Bodenheimer et al

Kinematics: Intro. Kinematics is study of motion

To Do. Advanced Computer Graphics. The Story So Far. Course Outline. Rendering (Creating, shading images from geometry, lighting, materials)

AMSTERDAM BOSTON HEIDELBERG LONDON NEW YORK OXFORD PARIS SAN DIEGO SAN FRANCISCO SINGAPORE SYDNEY TOKYO F ^ k.^

Course Outline. Advanced Computer Graphics. Animation. The Story So Far. Animation. To Do

Using RecurDyn. Contents

Accurate 3D Face and Body Modeling from a Single Fixed Kinect

Animation. CS 4620 Lecture 33. Cornell CS4620 Fall Kavita Bala

Interactive Computer Graphics

Anatomy of a Physics Engine. Erwin Coumans

4 Kinematic Linkages. Chapter 4. Kinematic Linkages. Department of Computer Science and Engineering 4-1

Kinematics and Orientations

Introduction to Computer Graphics. Animation (1) May 19, 2016 Kenshi Takayama

Practical Robotics (PRAC)

Autonomous and Mobile Robotics Prof. Giuseppe Oriolo. Humanoid Robots 2: Dynamic Modeling

13. Learning Ballistic Movementsof a Robot Arm 212

1. Introduction 1 2. Mathematical Representation of Robots

Motion Capture. Motion Capture in Movies. Motion Capture in Games

Rachel Weinstein, Joseph Teran and Ron Fedkiw

Ragdoll Physics. Abstract. 2 Background. 1 Introduction. Gabe Mulley, Matt Bittarelli. April 25th, Previous Work

Integrating Physics into a Modern Game Engine. Object Collision. Various types of collision for an object:

Model Library Mechanics

Kinematics & Motion Capture

CSE452 Computer Graphics

Computer Animation. Courtesy of Adam Finkelstein

Animation by Adaptation Tutorial 1: Animation Basics

Physically Based Character Animation

MOTION CAPTURE DATA PROCESSING - MOTION EDITING / RETARGETING - MOTION CONTROL / GRAPH - INVERSE KINEMATIC. Alexandre Meyer Master Informatique

MODELING AND HIERARCHY

Serial Manipulator Statics. Robotics. Serial Manipulator Statics. Vladimír Smutný

C O M P U T E R G R A P H I C S. Computer Animation. Guoying Zhao 1 / 66

CS 775: Advanced Computer Graphics. Lecture 17 : Motion Capture

Thiruvarangan Ramaraj CS525 Graphics & Scientific Visualization Spring 2007, Presentation I, February 28 th 2007, 14:10 15:00. Topic (Research Paper):

Motion Control Methods for Skeleton Daniel Thalmann

FAB verses tradition camera-based motion capture systems

KINEMATICS FOR ANIMATION. Rémi Ronfard, Animation, M2R MOSIG

How to Model Friction in SIMPACK

12.1 Quaternions and Rotations

Table of Contents. Chapter 1. Modeling and Identification of Serial Robots... 1 Wisama KHALIL and Etienne DOMBRE

MCE/EEC 647/747: Robot Dynamics and Control. Lecture 1: Introduction

CMSC 425: Lecture 10 Skeletal Animation and Skinning

Course Review. Computer Animation and Visualisation. Taku Komura

Chapter 4 Dynamics. Part Constrained Kinematics and Dynamics. Mobile Robotics - Prof Alonzo Kelly, CMU RI

3D Human Motion Analysis and Manifolds

DYNAMICS FOR ANIMATION. Rémi Ronfard, Animation, M2R MOSIG

Cloth Simulation. Tanja Munz. Master of Science Computer Animation and Visual Effects. CGI Techniques Report

Model-Based Human Motion Capture from Monocular Video Sequences

Robotics and Autonomous Systems

Robotics and Autonomous Systems

Transcription:

Motion Capture & Simulation

Motion Capture

Character Reconstructions

Joint Angles Need 3 points to compute a rigid body coordinate frame 1 st point gives 3D translation, 2 nd point gives 2 angles, 3 rd point gives the last angle Label markers by hand, so the system knows which three points to use for each rigid body/bone If markers disappear (become occluded), have to re-label them after they show back up (extensive manual intervention) Once both rigid bodies associated with a joint are identified, the joint angle can be determined Note: Due to errors, neighboring bones may disagree in the location of the joint

MoCap Hardware

Mechanical Motion Capture Actors wear sensorized mechanical joints that directly measure the rotation of human joints Reduces manual intervention, but expensive and cumbersome

Wiimote Wiimote optical sensor images LEDs Distance between the LEDs on the is bar fixed Distance between imaged LEDs varies with depth These two distances allow one to calculate how far away the remote is from the LED bar The angle of the remote is calculated from the angle the imaged LEDs make on the optical sensor

Inertial Tracking Wiimote (accelerometer) and Wiimotion Plus (gyroscope) Actors can also wear accelerometers and gyroscopes Accelerometers measure linear acceleration Solve the usual system of ODEs with known accelerations to obtain velocity and position (errors cause drift) Gyroscope sensors measure the angular velocity Solve the usual ODE to obtain orientation (errors cause drift)

Magnetic Motion Capture Place emitters that produce three orthonormal magnetic fields Actors wear magnetic field detectors/receivers Receivers detect the field strength, which gets weaker based on distance In addition to the accelerometer and gyroscope, the PSMove uses a magnetometer (and the Earth s magnetic field) to correct for drift from solving ODEs Also uses a separate optical camera that measures the location, size, and orientation of the sphere (which becomes an ellipse when projected)

Marker-less Motion Capture Actors wear nothing! Use computer vision to reconstruct the person Do a scan of a person ahead of time, and identify key points Match key points between the video and the scan Microsoft Kinect - inexpensive depth sensor (from structured light)

MoCap Data

Mocap Output Root position/orientation vs. time Angles vs. time for all joints For example

Using Mocap Mocap data can be mapped to a CG avatar anywhere in the scene by adding an arbitrary translation to the root position vs. time graph Subsequently the avatar moves as the mocap data prescribes Ignoring errors in the process But what if, for example, we have mocap data for walking straight and prefer to follow a curved path? Could capture mocap data for every possible curved path, but that requires a lot of data Similarly, could capture mocap data for every possible speed of movement One also needs data for transitions between different radii of curvature, transitions between different speeds, and all combinations of curvature and speeds Even more data is required for characters of different heights, since the angles and angles versus time will be different Etc. Thus, many methods exist for using mocap data which doesn t exactly fit the task at hand

Mocap Examples https://www.youtube.com/watch?v=bkkktchl5ow

Modifying MoCap Data

Inverse Kinematics Suppose a foot misses the ground, or a hand fails to touch a cup Select a key frame in the mocap that has such an issue Use IK to adjust the end effector to meet the desired goal Treat the null space by minimizing the change in joint angles required to meet the goal Finally use this new key frame data to (smoothly?) modify the surrounding mocap data (angle vs. time graphs)

Inverse Kinematics Use various 1D interpolation techniques (e.g. splines) to ensure that the new function: goes through the new key pose modifies the original function as little as possible remains smooth Etc.

Motion Editing/Warping More generally one can specify new key frames to serve any purpose (motion editing) And then modify the 1D functions of angle vs. time to respect the newly edited key frames (motion warping)

Spacetime Constraints Instead of specifying key frames, specify a number of constraints or goals throughout the time of the motion Then use constrained space/time optimization to find a new motion The optimization penalizes missing goals as well as the distance from the initial mocap data Besides goals for end effectors, more general constraints may include energy minimization, grace, style, efficiency, quality, etc. Expensive!

MoCap Transitions

Motion Transitions Typically, an avatar executes many different kinds of motion Need ways to transition from one motion type to another

Motion Blending Given two motions, say walking and running, how does one transition from walking to running? Use interpolation between the two motions: f t = A(t)(1 s(t)) + B(t)s(t) A(t) is the angle vs. time graph for walking B(t) is the angle vs. time graph for running f(t) is a new angle versus time graph that transitions from walking to running s(t) starts at 0 (walking) and at some point transitions to a value of 1 (running) Works ok in some cases Timings can be off, can look odd

Motion Graphs Automatically look for acceptable transition points between two separate motions Then cut, splice, and blend

MoCap & Simulation

Simulation Kinematically following mocap data gives the character infinite mass and inertia A little bit of physics can be added for realism

Interrupting Motion Capture If a character is given a small push, one can briefly simulate a reaction to collisions, etc., treating the character with finite mass After such a treatment, the character s state no longer matches that of the motion capture functions of angle vs. time Need to somehow recover Search for the closest motion capture frame to the current state and perform a motion graph transition

PD Control When an object is perturbed, keep targeting the current motion capture frame using a mass spring style formulation This gives a somewhat plausible transition back to the mocap angle vs. time functions from a perturbed state Apply a torque proportional to the difference between the current state and the target state Along with an additional damping torque proportional to the difference between the time derivatives ( angular velocities ) T = c P (q q d ) + c D ( qሶ qሶ d ) The larger the difference in the states, the bigger the torque The coefficients can be adjusted to more tightly or loosely follow the motion capture data

Rag Dolls The avatar can be simulated as an articulated rigid body Whether only for a brief collision, or for a longer period of time (e.g. falling down stairs) The articulated rigid body simulation would typically not be influenced by the motion capture data However, one could add a PD Control torque to the articulated rigid body simulation (as a non-physical, non-momentum conserving torque) in order to somewhat include the effects of mocap data in the simulation

Question #1 LONG FORM: Summarize motion capture technology. Answer the short form questions. SHORT FORM: Identify the main avatar in your game. How will the way it looks be compelling or relevant to the game? How will the way it moves be compelling or relevant to the game?

Articulated Rigid Bodies

Davy Jones

More than just characters

More than just characters

Maximal vs. Reduced Coordinates Broadly speaking, there are two ways of going about simulating articulated rigid bodies Maximal (Cartesian) Coordinates Simulate the full six degrees of freedom for each rigid body Use some auxiliary method to enforce joint constraints Contact, collision, friction, etc. are straightforward to include Reduced (Generalized) Coordinates Remove any degrees of freedom that are constrained away by joints write new differential equations for the position of the root and the joint angles) Faster to simulate, since there are less degrees of freedom Less intuitive equations, and less intuitive to incorporate contact, collision, friction and other unanticipated forces (but great for robots, since they re not supposed to have unanticipated forces)

Enforcing Constraints Consider constraining two separate rigid bodies together at a point Each of the rigid bodies describes this point in its own object space Thus we know the world space location of the two points that are supposed to be coincident The goal is to constrain them to actually be coincident For example one could attach a zero length spring connecting these two points, and simulate the effect of the spring forces on the rigid bodies

Fixing Drift Unless the zero length spring has infinite stiffness, which is difficult to simulate, the two points will drift somewhat apart This drift can be fixed at render time by projecting the current state of the rigid bodies into an acceptable joint state For example, each of the two bodies can be translated along the segment connecting their constrained points until those points are coincident In the case of a joint hierarchy one should only translate the rigid body further from the root A similar procedure can be employed for constraints on angles (which can be enforced using angular springs) Note: this may cause other visual issues such as interpenetrations One could maintain this new projected state as the new simulation state as well Although that then violates conservation of linear and angular momentum

Impulses for ARBs

Impulses Instead of using a spring to constrain the rigid bodies, one could use collision-style impulses Recall, an equal and opposite impulse is applied to each body using their impulse factors: u 1 new = u 1 + K 1 j and u 2 new = u 2 K 2 j The relative velocity u rel = u 1 u 2 should be identically zero after applying the impulse Solve u rel + K T j = 0 to find the impulse j The impulse is typically applied at the midpoint of the segment connecting the two points one is trying to keep coincident Unlike a spring that will fix the velocity and position, the impulse only fixes the velocity Thus, any position errors persist (creating drift that needs to be addressed)

Impulses for Drift During the position update, one could apply impulses to velocities in order to obtain velocities that close the gap That is, evolving the rigid bodies using these velocities results in the two points moving to become coincident (eliminating drift) Still use u new 1 = u 1 + K 1 j and u new 2 = u 2 K 2 j The new relative velocity u new rel is not set to zero, but rather to the correct velocity to close the gap Solve u rel + K T j = u new rel to find the impulse j Points on the rigid body move on nonlinear paths, since rigid bodies rotate and translate Thus, finding the correct relative velocity and impulse is difficult Requires a nonlinear solver, iterations, etc., but is doable After updating the position to remove drift, new impulses are needed in order to make the relative velocity zero as well (as per the last slide)

Angular Impulses for ARBs

Angular Impulse Recall: Equations for one body with collision location r p with respect to its center of mass: Mvҧ new = Mv ҧ + j Iω new = Iω + r p j Let the point of application (and thus r p ) go to infinity while j goes to zero with j τ = r p j remaining finite: Mvҧ new = Mv ҧ + 0 Iω new = Iω + j τ This angular impulse only effects the angular momentum and not the linear momentum: Mvҧ new = Mv ҧ + j Iω new = Iω + r p j + j τ

ҧ Angular Impulse The pointwise velocity gets additionally modified by the angular impulse: u new p = v new + ω new r p = vҧ new + r T p ω new u p new = v ҧ + j M + r p T ω + I 1 r p j + I 1 j τ u p new = u p + Kj + r p T I 1 j τ Similarly for the angular velocity: ω new = ω + I 1 r p j + I 1 j τ This gives us 2 vector valued equations for u p new and ω new in 2 vector valued unknowns j and j τ Thus we can target any velocity and angular velocity, constraining the joint together while also controlling its angle/rotation

Angular Impulse In addition to the relative velocity u rel = u 1 u 2 at the joint center, also consider the relative angular velocity ω rel = ω 1 ω 2 Equal and opposite impulses applied to each body: u new 1 = u 1 + K 1 j + r T 1 I 1 1 j τ u new 2 = u 2 K 2 j r T 2 I 1 2 j τ Equal and opposite angular impulses applied to each body: ω new 1 = ω 1 + I 1 1 r 1 j + I 1 1 j τ ω new 2 = ω 2 I 1 2 r 2 j I 1 2 j τ These equations can be combined and rewritten as: new = u rel + K T j + ( r T 1 I 1 1 + r T 2 I 1 2 ) j τ u rel ω new rel = ω rel + (I 1 1 r 1 + I 1 2 r 2 )j + (I 1 1 + I 1 2 ) j τ So given a desired relative velocity u new rel and a desired relative angular velocity ω new rel, we can solve for the impulse j and angular impulse j τ