CS 4730 Physical Simulation CS 4730 – Computer Game Design.

Slides:



Advertisements
Similar presentations
Time averages and ensemble averages
Advertisements

AP Physics C Mechanics Review.
Newton’s Laws of Motion
Real-Time Game Physics
F As a rocket accelerates it experiences a force F which is responsible for the acceleration. The reaction force to this force F (the other force in the.
Newton’s Laws 1. F. Newton’s Laws of Motion  Kinematics is the study of how objects move, but not why they move.  Sir Isaac Newton turned his attention.
Chapter 5: Forces and Newton’s Laws of Motion  Previously, we have studied kinematics, which - describes the motion of an object (x, v, a) - does not.
Force and Motion Force Newton’s First Law Newton’s Second Law Newton’s Third Law Gravitational Force Weight Normal Force pps by C Gliniewicz.
Circular Motion Like Projectile Motion, Circular Motion is when objects move in two directions at the same time.
Using the “Clicker” If you have a clicker now, and did not do this last time, please enter your ID in your clicker. First, turn on your clicker by sliding.
1Notes  Demetri Terzopoulos talk: Thursday, 4pm Dempster 310.
Game Physics Chris Miles. The Goal To learn how to create game objects with realistic physics models To learn how to simulate aspects of reality in order.
Department of Physics and Applied Physics , F2010, Lecture 20 Physics I LECTURE 20 11/21/10.
Weight is a force that is defined from the gravitational attraction between two masses. The gravitational force causes the less massive object to accelerate.
Force and Acceleration with respect to Circular Motion and the Concept of Pseudo Forces.
Vectors 1D kinematics 2D kinematics Newton’s laws of motion
Newton’s Laws Examples Physics 6A Prepared by Vince Zaccone For Campus Learning Assistance Services at UCSB.
Game Physics – Part I Dan Fleck Coming up: Rigid Body Dynamics.
THIS IS With Host... Your VocabularyFormulasNewton’s Laws Book Pull Lab Mystery ???
Newton’s Laws of Motion Dynamics After studying Kinematics, we know how to describe motion in two and three dimensions. But what causes this motion?
Teacher Reference Page This powerpoint is a presentation of Forces and Newton’s Laws. It probably goes through more than is necessary for students to know.
Newton’s Laws of Motion
Forces and the Laws of Motion
8-2 By: Victoria Griggs Davis November 10 th, 2010.
 Newton's laws of motion are three physical laws that together laid the foundation for classical mechanics. They describe the relationship between.
Force Newton’s Laws 1 First Law - Inertia Second Law – Force and Acceleration Third Law – Action and Reaction Introduction.
Honors Physics Newton’s First and Third Laws of Motion.
AP Physics C: Mechanics Chapter 11
Questions From Reading Activity? Big Idea(s):  The interactions of an object with other objects can be described by forces.  Interactions between.
PHYS16 – Lecture 10 & 11 Force and Newton’s Laws September 29 and October 1, 2010
When the axis of rotation is fixed, all particles move in a circle. Because the object is rigid, they move through the same angular displacement in the.
Copyright © 2010 Pearson Education South Asia Pte Ltd
Newton's Laws This is where the real physics begins. Physics is more than equations and math problems -- it is the laws of the universe and, most importantly,
Advanced Computer Graphics Rigid Body Simulation Spring 2002 Professor Brogan.
Newton’s Laws of Motion
Force Mass Motion How can I get the catapult to hit the target the first time?
WELCOME BACK MINIONS! Time to learn the Law!!!. NEWTON’S 1 ST LAW OF MOTION Newton’s First Law of Motion An object at rest will remain at rest unless.
College and Engineering Physics Newton’s Laws 1 TOC First Law - Inertia Second Law – Force and Acceleration Third Law – Action and Reaction Introduction.
How Force and Motion effect us every day! How can a roller coaster loop upside down and keep the passengers inside?
Introduction to Particle Simulations Daniel Playne.
Gravity and Motion. Gravity is what gives the universe its _________ A universal force that acts on _________ the objects in the universe Every particle.
Circular Motion Like Projectile Motion, Circular Motion is when objects move in two directions at the same time.
The Laws of Motion Newton’s Three Laws. What is a Force? It is something we experience every single day. You are exerting a force on your pencil right.
Newton’s Laws AP Physics C. Basic Definitions  Inertia  property of matter that resists changes in its motion.  Mass  measurement of inertia  Force.
NEWTON’S LAWS OF MOTION. Sir Isaac Newton  Born Jan. 4, 1643 in England.  As a young student, Newton didn’t do well in school.  He worked hard and.
Newton’s Laws of motion. Forces We have talked about different forces before but haven’t examined them in depth. A force is a push or a pull on an object.
Newton’s Third Law.
Rigid Body Dynamics CSE169: Computer Animation
General Principles 1 Engineering Mechanics: Statics in SI Units, 12e Copyright © 2010 Pearson Education South Asia Pte Ltd.
Newtons 3 rd law and momentum Newton worked in the 1600s. He talked about momentum before he talked about force but, maybe because momentum is hard.
Objectives. Objective The purpose of this tutorial is to teach the viewer how to solve for the acceleration of each mass in a standard two- body pulley.
1 Physics: Chapter 4 Forces & the Laws of Motion Topics:4-1 Changes in Motion 4-2 Newton’s First Law 4-3 Newton’s Second & Third Laws 4-4 Everyday Forces.
ERT 146 Engineering Mechanics Ms Siti Kamariah Md Sa’at School of Bioprocess Engineering, UniMAP
Advanced Computer Graphics Rigid Body Simulation
6.1 Force changes motion A force is a push or pull, or any action that is able to change motion.
Newton's Laws of Motion.
Introduction to Physics I
Newton’s Laws of Motion
Using the “Clicker” If you have a clicker now, and did not do this last time, please enter your ID in your clicker. First, turn on your clicker by sliding.
Newton’s Laws of Motion
FORCE Newton’s Laws: Kinematics vs. Dynamics Friction:
Impulse and Momentum Readings: Chapter 9.
AS-Level Maths: Mechanics 1 for Edexcel
Forces (Part the First)
Newton’s Laws Examples
Newton’s Laws of Motion
Newton's Laws Of Motion Teneighah Young.
Sir Isaac Newton.
Newtons' Laws A summary.
Presentation transcript:

CS 4730 Physical Simulation CS 4730 – Computer Game Design

CS 4730 First thing to realize… Physics (like, all of physics and doing all of physics) is HARD Physics in-game is HARD You (as beginning game designers… or as later pro game designers) probably do NOT want to do your own physics in many circumstances … well, it depends. 2

CS 4730 Kinematics vs. Dynamics Kinematics is the study of motion (position, velocity, acceleration) Dynamics is the full interactivity of all the forces in the environment You can handle kinematics You probably don’t want to handle dynamics So, we’ll use enough kinematics to make people believe it and “fake” the rest! Yes. Fake it. 3

CS 4730 Immersion in the World When a ball hits a paddle or brick in Breakout, how does it behave? e+2 4

CS 4730 Immersion in the World How does the ball react? Why does it react the way it does? How does it react differently if it hits in the middle of the paddle vs. the edge of the paddle? 5

CS 4730 Immersion in the World Why does the ball behave like this? Is this an “accurate” portrayal of the world? What’s wrong with the physics here? 6

CS 4730 Physics in Games So the question is not always “how do we model precise physics” But more often it’s “how do we model a physics that makes sense in this world” “The correct physics” is often essential to a positive play experience and also fosters new dynamics in a game Remember: physics is the mathematical study of the physical world 7

CS 4730 The Role of Physics Detect Collisions Responsive forces Accumulate Forces Equations of Motion Numerical Integration Updated world at Δt in the future Enforce Constraints Adjust world to maintain user constraints 8

CS 4730 Basic Overall Idea Assume you have a simple particle You know it’s current start position You know it’s current velocity and acceleration You know the current forces working on it You know (or can adjust) the time until the next frame to draw Where’s the particle when the next frame is drawn? 9

CS 4730 How do we pull this off? Roll your own –Pull out your physics book (or don’t as the game requires) and go to town –Perhaps crazy physics is a mechanic in your game –Consider the physics of Breakout –What do you have to calculate? –How do you change from frame to frame? 10

CS 4730 How do we pull this off? Pull in a package –Unity –Havoc –PhysX (hardware acceleration) –Chipmunk –Farseer (what you would probably use) 11

CS 4730 Particle Kinematics - Position What is a Particle? –A sphere of finite radius with a perfectly smooth, frictionless surface –Experiences no rotational motion Particle Kinematics –Defines the basic properties of particle motion –Position, Velocity, Acceleration 12

CS 4730 Newton’s Laws First Law: An object in motion will remain in motion unless acted upon by external force. Second Law: Force = Mass * Acceleration Third Law: Every action has an equal and opposite reaction. 13

CS 4730 Variables t x The final time for the period we are examining t 0 The initial time  tThe change in time (t x – t 0 ) for the period we are examining  vThe change in velocity (v x – v 0 ) for the period we are examining  aThe change in acceleration (a x – a 0 ) for the period we are examining 14

CS 4730 Change in Velocity Assume the acceleration (and mass and thus force) is constant The velocity at a given time is the sum of: –the initial velocity –the change due to the acceleration 15

CS 4730 Change in Position Assume the acceleration (and mass and thus force) is constant The position at a given time is the sum of: –the initial position –the position change due to the initial velocity –The position change due to the acceleration 16

CS 4730 The Problem With Integration It’s all an approximation If the Δt is too big, then you get really imprecise physics If the Δt is too small, your processor can’t handle it all If it happens in a single frame, all variables are constant How do curved trajectories turn out? 17

CS 4730 It Gets Worse… Rigid body physics adds in volume and mass So now, we are focusing our equations on the center of mass of the body… but other things could also happen, such as torque 18

CS 4730 Looking at Physics Code Let’s look at Farseer physics again… How about another game? 19

CS 4730 Different Physics Why are these built differently? Why does this matter? –Mechanics perspective –Dynamics perspective –Aesthetics perspective 20