Comp 304 computer graphics ii
Download
1 / 90

COMP 304 - PowerPoint PPT Presentation


  • 325 Views
  • Updated On :

COMP 304 Computer Graphics II. LECTURE 8 MOTION CONTROL – FORWARD KINEMATICS Dr. Mehmet Gokturk Asst. Prof., Gebze Institute of Technology. Some Timeline  The Illusion of Motion. 1824, Peter Mark Roget," Persistence of Vision with Regard to Moving Objects “

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'COMP 304' - medwin


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
Comp 304 computer graphics ii l.jpg

COMP 304Computer Graphics II

LECTURE 8

MOTION CONTROL – FORWARD KINEMATICS

Dr. Mehmet GokturkAsst. Prof., Gebze Institute of Technology


Some timeline the illusion of motion l.jpg
Some Timeline  The Illusion of Motion

  • 1824, Peter Mark Roget,"Persistence of Vision with Regard to Moving Objects“

  • a series of images shown in rapid sequence can appear to move fluidly (i.e. a flip book or film projector)

© M. Gokturk



Timeline movies l.jpg
Timeline  Movies

  • (1895) age of movie camera and projector begins

    • experimentors discover they can stop the crank and restart it again to obtain special effects

  • (1914) Gertie, Windsor McCay (newspaper cartoonist)

    • first popular animation

  • (1928) Steamboat Willie, Disney

    • an early cartoon w/ sound

    • cartoons seem plausible as entertainment

  • (1933) King Kong, Willis O’Brien

  • (1930’s & 40’s) Golden age of cartoons

    • Betty Boop, Popeye, Porky Pig, Daffy Duck, Bugs Bunny, Woody Woodpecker, Mighty Mouse, Tom & Jerry

  • (1937) Snow White, Disney

    • animated feature film

    • cost is $1.5M

© M. Gokturk


Timeline movies cont l.jpg
Timeline  Movies (cont)

  • (1982) Tron, MAGI

    • movie with a computer graphics premise

  • (1984) Last Starfighter

    • computer graphics was used interchangably with actual models of the spaceship

  • (1993) Jurassic Park

    • computer graphics is used to create living creatures that are meant to appear realistic

  • (1995) Toy Story, Pixar

    • full-length feature film done entirely with 3D computer animation

  • (2000) CyberWorld 3D, IMAX

    • 3D IMAX full-length feature film including characters from popular 3D movies such as ANTZ and The Simpsons’ Homer

© M. Gokturk


Conventional animation techniques l.jpg
Conventional Animation Techniques

  • Drawing on film

  • Multiple drawings

  • Rotoscoping (project film of real actors onto drawing paper)

  • Stop motion animation

  • Acetate cels, multiple plane cells

© M. Gokturk


Conventional animation process l.jpg
Conventional Animation Process

  • Storyboard

  • Key frames drawn

    • Straight ahead vs. pose-to-pose

  • Intermediate frames filled in (inbetweening)

  • Trial film is made (called a pencil test)

  • Pencil test frames transferred to cels

© M. Gokturk



Role of the computer l.jpg
Role of the Computer

  • In-betweening

    • artistic example: Hunger, Peter Foldes 1974

  • Disney’s CAPS system

    • scanned artist drawings are read in

    • "cels" are colored online (broad color palette, exact color matching)

    • compositing is done online (background, 2D drawings, 3D animation)

    • 3D effects can be created with 2D drawings (e.g. Beauty and the Beast)

    • used in every film since Beauty & Beast

  • 3D graphical worlds

    • can experiment more easily with actor position, camera position

    • can perform more complex camera moves

    • exchange labor to create drawings with labor to build and animate 3D world

© M. Gokturk


3d animation l.jpg
3D Animation

  • 3D animation is similar to stop motion animation

King Kong (1932)

http://www.stopmotionanimation.com/

Flash Gordon (1972)

© M. Gokturk


3d animation11 l.jpg
3D Animation

  • Stop motion animation (Nightmare Before Christmas)

  • 3D keyframing(Luxo Jr.)

  • Performance animation and motion capture (Donkey Kong Country)

  • Which must be done straight-ahead and which can be animated pose-topose?

© M. Gokturk


Keyframing l.jpg
Keyframing

  • Key frames mark important visual transitions (extremes of action)

  • Inbetweening is creation of intermediate frames between the key frames

  • Can easily be calculated by computer

© M. Gokturk


Temporal sampling l.jpg
Temporal Sampling

  • Film recording takes samples of an image at fixed time intervals

    • 24 frames per second for film

    • 30 frames per second for video

  • human eye "sees" continuous motion

Sometimes, fewer keyframes are required to describe the motion, especially for “pencil tests” or rough choreography (e.g., Lost World)

© M. Gokturk


Smooth motion passive physics l.jpg
Smooth Motion  Passive Physics

  • No internal energy source and move only when an external force acts on them.

  • Read for use when:

    • physical laws encoded

    • initial conditions specified

  • Pools of water, clothing, hair, leaves

© M. Gokturk


Smooth motion passive physics15 l.jpg
Smooth Motion  Passive Physics

  • Clothing (Geri’s Game)

  • Water (Antz)

  • “Rigid” body physics (crashing space pods in Phantom Menace)

Geri’s Game, Pixar Animation Studios

© M. Gokturk

See examples


Smooth motion active physics l.jpg
Smooth Motion  Active Physics

  • User specifies keyframes (start, end, middle)

  • User specifies constraints (e.g. laws of physics)

  • System searches for minimum energy motion to accomplish goals

A. Witkin and M. Kass,

“Spacetime Constraints”,

SIGGRAPH ‘88.

© M. Gokturk


Smooth motion active physics and simulation l.jpg
Smooth Motion  Active Physics and Simulation

  • Control an animated character as we would control a robot

  • behavior is simulated

  • a "control system" sends proper signals to the character’s "muscles" over time

Mark Raibert’s leg lab at MIT

http://www.ai.mit.edu/projects/leglab/

© M. Gokturk


Noise motion l.jpg
Noise Motion

  • We generally don’t want motion to be too smooth

  • The eye picks up symmetries and smooth curves and interprets them as artificial or fake

  • By adding noise, we can add texture to smooth motion

K. Perlin, “An Image Synthesizer”,

Computer Graphics, 19(3), July 1985.

Perlin, Improv system

(K. Perlin and A. Goldberg, SIGGRAPH ‘96).

Applets: http://www.mrl.nyu.edu/~perlin/

© M. Gokturk


Noise motion19 l.jpg
Noise Motion

  • Motion capture (natural noise!)

© M. Gokturk


Camera path following l.jpg
Camera Path Following

  • A simple type of animation  everything remains static except the camera (walk throughs or flybys).

  • The camera  just as any other object as far as orientation and positioning is concerned.

  • The user needs to construct a path through space for the observer to follow along with orientation information.

  • Path = key frame positioning + interpolation of the inbetween frames.

© M. Gokturk


Camera path following ways to deal with the view direction 1 l.jpg
Camera Path Following  ways to deal with the view direction (1)

  • The center of interest can be held constant while observer position is interpolated along a curve

  • View Direction  Vector between the observer position (POS) and the center of interest (COI)

  • This is useful when the observer is flying over an environment inspecting a specific location such as a building.

© M. Gokturk


Camera path following ways to deal with the view direction 2 l.jpg
Camera Path Following  ways to deal with the view direction (2)

  • A path for the center of interest can be constructed, say from a series of buildings in an environment.

  • Often, the animator will want the center of interest to stay focused on one building for a few frames before it goes to the next building.

© M. Gokturk


Camera path following ways to deal with the view direction 3 l.jpg
Camera Path Following  ways to deal with the view direction (3)

  • Alternatively, the center of interest can be controlled by other points along the observer path.

  • For example, observer position for the next frame can be used to determine the view direction for the current frame.

  • Sometimes this is too jerky. Some nth frame beyond the current frame can be used to produce a smoother view direction.

© M. Gokturk


Camera path following ways to deal with the view direction 4 l.jpg
Camera Path Following  ways to deal with the view direction (4)

  • The center of interest can also be attached to objects in the animation.

© M. Gokturk


Path following l.jpg
Path following

  • Have position and orientation interpolation for key framing now

  • Combining them , get general motions of rigid objects

    • Add scaling, get stretching/squashing

  • Path following:

    • Have keys only for position

    • how to change orientation “naturally”

  • Same techniques for camera motion

© M. Gokturk


Orientation along a path l.jpg
Orientation along a path

  • It’s natural to change orientation as things move

  • Example: looking while walking

    • Look in the direction one walks

  • Tedious to specify orientations along the way

  • Want to get directly from the path

© M. Gokturk


Frenet frame moving frame l.jpg
Frenet frame (Moving frame)

  • At each point on the curve:

    • Get Tangent vector

    • Get vector in general curvature direction

      • In the plane of tangent and curvature vector

    • Vector orthogonal to the two

  • Math:

  • Everything is normalized then

© M. Gokturk




Frenet frame l.jpg
Frenet frame

  • Curvature can be zero along extended parts

    • Example: straight line

  • Solution: interpolate boundary frames

    • Differ only by rotation around the straight line

  • Zero curvature at a point:

    • Possible flip (ex. camera flips upside down)

  • Discontinuities in curvature:

    • Sudden changes of object orientation

  • These effects are NOT tolerable

© M. Gokturk


Alternatives l.jpg
Alternatives

  • Tangent vector is ok for objects

    • Poor choice for cameras

  • For cameras: Look at the “center of interest”

    • Fixed COI: Always look at particular point

    • Separate path for COI

      • Can animate this point separately using extra key positions

© M. Gokturk


Alternatives32 l.jpg
Alternatives

  • COI (center of interest) travels in front of the camera

    • COI(s)=P(s+ds)

    • At the end, along the final tangent vector

  • Choose several ds, average

    • Smoothes motion

    • Trade-off: jerky motion vs. too static view direction

  • “Up” vector:

    • In the plane of view vector and global UP vector

    • Extra offset from this direction

    • Full key framing

© M. Gokturk



Slide34 l.jpg

u = P’(u) x P’’(u)

w = P’(u)

P’’(u)

v = w x u

Path Following

Frenet Frame

© M. Gokturk


Slide35 l.jpg

Curvature continuity

=0

© M. Gokturk


Slide36 l.jpg

Look ahead

© M. Gokturk



Slide38 l.jpg

Define “up” vector

© M. Gokturk






Kinematics x dynamics l.jpg
Kinematics X Dynamics

© M. Gokturk


Kinematics l.jpg
Kinematics

© M. Gokturk


Kinematics45 l.jpg
Kinematics

  • Keyframing requires that the user supply the key frames

  • For articulated figures, we need a way to define the key frames

  • There are two ways to pose an articulated character – forward and inverse kinematics

  • Kinematics is the study of motion without regard to the forces that cause the motion Kinematics

© M. Gokturk



Articulated models l.jpg
Articulated Models

Articulated models:

  • rigid parts

  • connected by joints

    They can be animated by specifying the joint angles (or other display parameters) as functions of time.

See example animation clips

© M. Gokturk









Forward kinematics l.jpg
Forward Kinematics

© M. Gokturk


Forward kinematics56 l.jpg
Forward Kinematics

© M. Gokturk


Forward kinematics57 l.jpg
Forward Kinematics

© M. Gokturk


Forward kinematics58 l.jpg
Forward Kinematics

© M. Gokturk


Slide59 l.jpg

Forward Kinematics

Hierarchical model - joints and links

Joints - rotational or prismatic

Joints - 1, 2, or 3 Degree of Freedom

Links - displayable objects

Pose - setting parameters for all joint DoFs

Pose Vector - a complete set of joint parameters

© M. Gokturk



Slide61 l.jpg

T

R

S

data

Forward Kinematics

© M. Gokturk


Slide62 l.jpg

T0

T1.1

T2.1

R2.1

R1.1

T2.2

T1.2

R2.2

R1.2

Transformations at the arcs

User modifies

Rotation

(new “pose vector”)

Re-traverse tree

To get new “pose”

© M. Gokturk


Forward kinematics63 l.jpg
Forward Kinematics

Describes the positions of the body parts as a function of the joint angles.

1 DOF: knee

2 DOF: wrist

3 DOF: arm

© M. Gokturk


Slide64 l.jpg

q

Joint Representation

Degree of Freedom

DOF

Joint Limits

© M. Gokturk


Slide65 l.jpg

q

y

w

Joint Representation

Multiple

Degrees of Freedom

Joint Limits

gimbal lock

Axis-angle

quaternions

© M. Gokturk


Slide66 l.jpg

q

y

w

Joint Representation

Note

User interface representation may not be the same used for internal representation and operations

© M. Gokturk







Slide72 l.jpg

Denavit and Hartenberg

Standard method of describing relationship of one DOF to next

Used extensively in robotics

Used in some early animation systems

Multiple DOF joints represented by zero-length parameters

© M. Gokturk








Skeleton hierarchy l.jpg
Skeleton Hierarchy

  • Each bone transformation described relative to the parent in the hierarchy:

hips

...

left-leg

r-thigh

r-calf

r-foot

© M. Gokturk


Forward kinematics80 l.jpg

vs

y

vs

x

z

Forward Kinematics

  • Transformation matrix for a sensor/effecter vsis a matrix composition of all joint transformation between the sensor/effecter and the root of the hierarchy.

vs

© M. Gokturk




Slide83 l.jpg

  • Four link deep appendage with a branch after the second link

  • The first and third links have two degrees of freedom, the others have one.

  • The first frame is defined by rotation angles ((0,0),0,[(30,0),-15],[(-30,0),15]

  • The last frame is defined by rotation angles ((-30,60),-80,[(90,30),-135],[(-90,30),135]

© M. Gokturk








Summary l.jpg
Summary

© M. Gokturk


ad