SlideShare a Scribd company logo
1 of 49
Download to read offline
Physics Solutions for
    Innovative Game Design
Give your iPhone games a dynamic real-world
     feel by integrating a physics engine.


                       Andrei Gradinari
                       Lead Engineer - Backflip Studios

                       Tom Blind
                       Lead Designer - Backflip Studios
History of Physics in Games
            and
     "Physics Games"
History of Physics in Games
Very simple physics (Late 80-s to Early 90-s) - Racing games,
flight sims, mini golf games, etc ...
History of Physics in Games
Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half-
Life, many others
History of Physics in Games
Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half-
Life, many others
History of Physics in Games
Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half-
Life, many others
History of Physics in Games
Complex real physics (Early 2000s) - Half-Life 2
History of Physics in Games
Complex real physics (Early 2000s) - Half-Life 2
History of Physics in Games
Complex real physics (Early 2000s) - Half-Life 2
History of Physics in Games
Complex real physics (Early 2000s) - Prey
Prey: Flip Gravity Gameplay Mechanic
        (how to get to the box with candy)
Prey: Flip Gravity Gameplay Mechanic
        (how to get to the box with candy)
Prey: Flip Gravity Gameplay Mechanic
        (how to get to the box with candy)
History of Physics in Games
Physics on GPUs: Almost real world complexity (Middle to Late
2000's)
Crysis engine 3000 Barrels, real time:
History of Physics in Games
Physics on GPUs: Almost real world complexity (Middle to Late
2000's)
What is a Physics Game?
What is a Physics Game?
These are NOT physics games
  Even though they use physics

          Doom 3                 Unreal
What is a Physics Game?
These are physics games!


    Crayon Physics         Fantastic Contraption
Physics Engine
Definition and How It Works
Physics Engine

A physics engine is a set of
functions that lets you describe
layout of your system of physics
objects and then tells you how the
state of this system changes over
time.
Physics Engine
Define layout of your system of objects (shapes, positions,
masses, dimensions, global gravity vector, etc...)
Physics Engine
The engine tells you how your system changes over time
Physics Simulation
The process handled by a physics engine that figures out what
happens to the given set of objects over a certain period of time
is called physics simulation




                       ->Simulation->
Physics Simulation

Can be:
   Not Interactive (user input is not taken in consideration)

   Interactive (user input affects the simulation). Interactive
   simulations are used in most games
Do you need a physics engine?
Do you need a physics engine?

Sometimes, it's easier to do it yourself!

       Less memory & CPU usage
       Less disk space
       Less time spent linking libraries
       Simpler, if you don't need anything fancy
Do you need a physics engine?
Rolling your own physics:
                acceleration = force / mass
 Things get trickier with collisions...
The Physics of Paper Toss
                Forces are one-dimensional

                Add flick force and wind force
                to determine landing point

                Animate to make it look pretty

                No physics library needed!
Typical Physics Engine
Typical Physics Engine


Consists of:

  Rigid Body Dynamics Simulation Engine

  Collision Detection Engine
Typical Physics Engine
Building blocks of your physics world:
Geometric Shapes (describe what your objects look like)




Joints (describe how your objects are connected to each other)
Typical Physics Engine

Simulation Step:
  Collision contact points generation (collision detection
  engine)

  Creating temporary joints based on contact points, and
  attaching them to respective physics objects

  Performing actual simulation step (rigid body dynamics
  engine)
Simple Simulation Example (Step 1)
Simple Simulation Example (Step 2)
Simple Simulation Example (Step 3)
Performance Tips and
       Tricks
Performance Tips and Tricks
Keep things simple
  More objects in your physics simulation = more time
  spent to simulate the system = lower framerate as a
  result.

Approximate complex volumes with sets of simple
volumes
  Performance gain is well worth it.
  User will never see the difference, as long as you do it
  right.
  It's still fine to render fully detailed models, while
  simulating simple shapes on the physics side.
Performance Tips and Tricks
Example of complex volumes approximation.
Rendered models:
Performance Tips and Tricks
Example of complex volumes approximation.
Simulated shapes:
Performance Tips and Tricks
 Do not simulate static objects
   They should never be simulated in Rigid Bodies
   Dynamics Engine, because they never move.

 Do not simulate dynamic objects that are
 stationary at the moment.
   ODE, for example, automatically does this for you. It is
   called Auto Disable.

 Use spatial partitioning

 Setup collision detection engine to generate as
 few contact points as possible
Performance Tips and Tricks
Several small steps vs one large step

Several small steps:            One large step:

   More realistic simulation,      Less realistic simulation
   especially when
   simulating dynamically          Better performance
   changing forces

   Less problems with
   objects flying through
   each other.
Performance Tips and Tricks
Probable instability problems with simulation and
their causes:
  Large simulation step

  Large forces applied to bodies

  Large masses, especially when mixed with small masses

  High speeds of the objects

  Fast spinning objects

  High friction
A Brief Comparison of Physics Engines
          Used on the iPhone


            2D          3D
          Box2D        ODE
          Chipmunk     Bullet
Comparison of Physics Engines
Box2D
  Optimized for 2D games
  Works well with cocos2d
  Used in many iPhone games such as Crayon Physics and
  Rolando
Comparison of Physics Engines
Chipmunk
  Very lightweight
  Written in pure C
  Made by the creators of Crayon Ball for the iPhone
  "Makes you smarter, stronger, and more attractive to the
  opposite gender!"
Comparison of Physics Engines
Open Dynamics Engine (ODE)
  Industry veteran
  Supports full 3D simulation
  Fast, even on the iPhone
  Used in Touchgrind and Ragdoll Blaster
Comparison of Physics Engines
Bullet Physics Library
  Highly optimized for many architectures
  Multi-threaded
  Third most popular physics library according to survey by
  Game Developer Magazine (Aug. 2009)
  Used by Oolong Engine (Kids vs. Zombies, iPhysics)
Contemporary physics in games on
consoles and PC's = the nearest future
of physics in mobile games...
Thanks!


jobs@backflipstudios.com

More Related Content

Similar to Physics Solutions for Innovative Game Design

111 physicsdynamics research
111 physicsdynamics research111 physicsdynamics research
111 physicsdynamics researchRyan Worcester
 
[SP02] Developing autonomous vehicles with AirSim
[SP02] Developing autonomous vehicles with AirSim[SP02] Developing autonomous vehicles with AirSim
[SP02] Developing autonomous vehicles with AirSimde:code 2017
 
SPU Physics
SPU PhysicsSPU Physics
SPU PhysicsSlide_N
 
Parallelizing Conqueror's Blade
Parallelizing Conqueror's BladeParallelizing Conqueror's Blade
Parallelizing Conqueror's BladeIntel® Software
 
Crm saturday madrid 2017 jordi montaña - test automation
Crm saturday madrid 2017   jordi montaña - test automationCrm saturday madrid 2017   jordi montaña - test automation
Crm saturday madrid 2017 jordi montaña - test automationDemian Raschkovan
 
Crm Saturday Madrid - Test Automation for Dynamics 365
Crm Saturday Madrid  - Test Automation for Dynamics 365Crm Saturday Madrid  - Test Automation for Dynamics 365
Crm Saturday Madrid - Test Automation for Dynamics 365Jordi Montaña
 
4.3 real time game physics
4.3 real time game physics4.3 real time game physics
4.3 real time game physicsSayed Ahmed
 
Session 01 – introduces maya dynamics
Session 01 – introduces maya dynamicsSession 01 – introduces maya dynamics
Session 01 – introduces maya dynamicsTrí Bằng
 
Optimizing Large Scenes in Unity
Optimizing Large Scenes in UnityOptimizing Large Scenes in Unity
Optimizing Large Scenes in UnityNoam Gat
 
You've got the power?
You've got the power?You've got the power?
You've got the power?Looptribe
 
Engineering + Programming portfolio
Engineering + Programming portfolioEngineering + Programming portfolio
Engineering + Programming portfolioJosephDonnelly14
 
GDC2011 - Implementation and Application of the Real-Time Helper-Joint System
GDC2011 - Implementation and Application of the Real-Time Helper-Joint SystemGDC2011 - Implementation and Application of the Real-Time Helper-Joint System
GDC2011 - Implementation and Application of the Real-Time Helper-Joint SystemJubok Kim
 
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptx
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptxCIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptx
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptxMAWILICLEMENTJONRAYV
 
Kinematic cellularautomata
Kinematic cellularautomataKinematic cellularautomata
Kinematic cellularautomataClifford Stone
 
FGS 2011: Making A Game With Molehill: Zombie Tycoon
FGS 2011: Making A Game With Molehill: Zombie TycoonFGS 2011: Making A Game With Molehill: Zombie Tycoon
FGS 2011: Making A Game With Molehill: Zombie Tycoonmochimedia
 
Insomniac Physics
Insomniac PhysicsInsomniac Physics
Insomniac PhysicsSlide_N
 
Monte carlo methods in graphics and hacking
Monte carlo methods in graphics and hackingMonte carlo methods in graphics and hacking
Monte carlo methods in graphics and hackingHimanshu Goel
 

Similar to Physics Solutions for Innovative Game Design (20)

111 physicsdynamics research
111 physicsdynamics research111 physicsdynamics research
111 physicsdynamics research
 
[SP02] Developing autonomous vehicles with AirSim
[SP02] Developing autonomous vehicles with AirSim[SP02] Developing autonomous vehicles with AirSim
[SP02] Developing autonomous vehicles with AirSim
 
SPU Physics
SPU PhysicsSPU Physics
SPU Physics
 
Parallelizing Conqueror's Blade
Parallelizing Conqueror's BladeParallelizing Conqueror's Blade
Parallelizing Conqueror's Blade
 
Crm saturday madrid 2017 jordi montaña - test automation
Crm saturday madrid 2017   jordi montaña - test automationCrm saturday madrid 2017   jordi montaña - test automation
Crm saturday madrid 2017 jordi montaña - test automation
 
Crm Saturday Madrid - Test Automation for Dynamics 365
Crm Saturday Madrid  - Test Automation for Dynamics 365Crm Saturday Madrid  - Test Automation for Dynamics 365
Crm Saturday Madrid - Test Automation for Dynamics 365
 
4.3 real time game physics
4.3 real time game physics4.3 real time game physics
4.3 real time game physics
 
Session 01 – introduces maya dynamics
Session 01 – introduces maya dynamicsSession 01 – introduces maya dynamics
Session 01 – introduces maya dynamics
 
Optimizing Large Scenes in Unity
Optimizing Large Scenes in UnityOptimizing Large Scenes in Unity
Optimizing Large Scenes in Unity
 
You've got the power?
You've got the power?You've got the power?
You've got the power?
 
Engineering + Programming portfolio
Engineering + Programming portfolioEngineering + Programming portfolio
Engineering + Programming portfolio
 
GDC2011 - Implementation and Application of the Real-Time Helper-Joint System
GDC2011 - Implementation and Application of the Real-Time Helper-Joint SystemGDC2011 - Implementation and Application of the Real-Time Helper-Joint System
GDC2011 - Implementation and Application of the Real-Time Helper-Joint System
 
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptx
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptxCIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptx
CIS Project - Computer Parts vs. Human Body Parts PowerPoint.pptx
 
Kinematic cellularautomata
Kinematic cellularautomataKinematic cellularautomata
Kinematic cellularautomata
 
FGS 2011: Making A Game With Molehill: Zombie Tycoon
FGS 2011: Making A Game With Molehill: Zombie TycoonFGS 2011: Making A Game With Molehill: Zombie Tycoon
FGS 2011: Making A Game With Molehill: Zombie Tycoon
 
Insomniac Physics
Insomniac PhysicsInsomniac Physics
Insomniac Physics
 
Monte carlo methods in graphics and hacking
Monte carlo methods in graphics and hackingMonte carlo methods in graphics and hacking
Monte carlo methods in graphics and hacking
 
Unity
UnityUnity
Unity
 
fast things slidedoc
fast things slidedocfast things slidedoc
fast things slidedoc
 
Blender Basics
Blender BasicsBlender Basics
Blender Basics
 

More from John Wilker

Cranking Floating Point Performance Up To 11
Cranking Floating Point Performance Up To 11Cranking Floating Point Performance Up To 11
Cranking Floating Point Performance Up To 11John Wilker
 
Introtoduction to cocos2d
Introtoduction to  cocos2dIntrotoduction to  cocos2d
Introtoduction to cocos2dJohn Wilker
 
Getting Started with OpenGL ES
Getting Started with OpenGL ESGetting Started with OpenGL ES
Getting Started with OpenGL ESJohn Wilker
 
User Input in a multi-touch, accelerometer, location aware world.
User Input in a multi-touch, accelerometer, location aware world.User Input in a multi-touch, accelerometer, location aware world.
User Input in a multi-touch, accelerometer, location aware world.John Wilker
 
Getting Oriented with MapKit: Everything you need to get started with the new...
Getting Oriented with MapKit: Everything you need to get started with the new...Getting Oriented with MapKit: Everything you need to get started with the new...
Getting Oriented with MapKit: Everything you need to get started with the new...John Wilker
 
Getting Started with iPhone Game Development
Getting Started with iPhone Game DevelopmentGetting Started with iPhone Game Development
Getting Started with iPhone Game DevelopmentJohn Wilker
 
Internationalizing Your Apps
Internationalizing Your AppsInternationalizing Your Apps
Internationalizing Your AppsJohn Wilker
 
Optimizing Data Caching for iPhone Application Responsiveness
Optimizing Data Caching for iPhone Application ResponsivenessOptimizing Data Caching for iPhone Application Responsiveness
Optimizing Data Caching for iPhone Application ResponsivenessJohn Wilker
 
I Phone On Rails
I Phone On RailsI Phone On Rails
I Phone On RailsJohn Wilker
 
Integrating Push Notifications in your iPhone application with iLime
Integrating Push Notifications in your iPhone application with iLimeIntegrating Push Notifications in your iPhone application with iLime
Integrating Push Notifications in your iPhone application with iLimeJohn Wilker
 
Starting Core Animation
Starting Core AnimationStarting Core Animation
Starting Core AnimationJohn Wilker
 
P2P Multiplayer Gaming
P2P Multiplayer GamingP2P Multiplayer Gaming
P2P Multiplayer GamingJohn Wilker
 
Using Concurrency To Improve Responsiveness
Using Concurrency To Improve ResponsivenessUsing Concurrency To Improve Responsiveness
Using Concurrency To Improve ResponsivenessJohn Wilker
 
Leaving Interface Builder Behind
Leaving Interface Builder BehindLeaving Interface Builder Behind
Leaving Interface Builder BehindJohn Wilker
 
Mobile WebKit Development and jQTouch
Mobile WebKit Development and jQTouchMobile WebKit Development and jQTouch
Mobile WebKit Development and jQTouchJohn Wilker
 
Accelerometer and OpenGL
Accelerometer and OpenGLAccelerometer and OpenGL
Accelerometer and OpenGLJohn Wilker
 
Deep Geek Diving into the iPhone OS and Framework
Deep Geek Diving into the iPhone OS and FrameworkDeep Geek Diving into the iPhone OS and Framework
Deep Geek Diving into the iPhone OS and FrameworkJohn Wilker
 
NSNotificationCenter vs. AppDelegate
NSNotificationCenter vs. AppDelegateNSNotificationCenter vs. AppDelegate
NSNotificationCenter vs. AppDelegateJohn Wilker
 
From Flash to iPhone
From Flash to iPhoneFrom Flash to iPhone
From Flash to iPhoneJohn Wilker
 

More from John Wilker (20)

Cranking Floating Point Performance Up To 11
Cranking Floating Point Performance Up To 11Cranking Floating Point Performance Up To 11
Cranking Floating Point Performance Up To 11
 
Introtoduction to cocos2d
Introtoduction to  cocos2dIntrotoduction to  cocos2d
Introtoduction to cocos2d
 
Getting Started with OpenGL ES
Getting Started with OpenGL ESGetting Started with OpenGL ES
Getting Started with OpenGL ES
 
User Input in a multi-touch, accelerometer, location aware world.
User Input in a multi-touch, accelerometer, location aware world.User Input in a multi-touch, accelerometer, location aware world.
User Input in a multi-touch, accelerometer, location aware world.
 
Getting Oriented with MapKit: Everything you need to get started with the new...
Getting Oriented with MapKit: Everything you need to get started with the new...Getting Oriented with MapKit: Everything you need to get started with the new...
Getting Oriented with MapKit: Everything you need to get started with the new...
 
Getting Started with iPhone Game Development
Getting Started with iPhone Game DevelopmentGetting Started with iPhone Game Development
Getting Started with iPhone Game Development
 
Internationalizing Your Apps
Internationalizing Your AppsInternationalizing Your Apps
Internationalizing Your Apps
 
Optimizing Data Caching for iPhone Application Responsiveness
Optimizing Data Caching for iPhone Application ResponsivenessOptimizing Data Caching for iPhone Application Responsiveness
Optimizing Data Caching for iPhone Application Responsiveness
 
I Phone On Rails
I Phone On RailsI Phone On Rails
I Phone On Rails
 
Integrating Push Notifications in your iPhone application with iLime
Integrating Push Notifications in your iPhone application with iLimeIntegrating Push Notifications in your iPhone application with iLime
Integrating Push Notifications in your iPhone application with iLime
 
Starting Core Animation
Starting Core AnimationStarting Core Animation
Starting Core Animation
 
P2P Multiplayer Gaming
P2P Multiplayer GamingP2P Multiplayer Gaming
P2P Multiplayer Gaming
 
Using Concurrency To Improve Responsiveness
Using Concurrency To Improve ResponsivenessUsing Concurrency To Improve Responsiveness
Using Concurrency To Improve Responsiveness
 
Leaving Interface Builder Behind
Leaving Interface Builder BehindLeaving Interface Builder Behind
Leaving Interface Builder Behind
 
Mobile WebKit Development and jQTouch
Mobile WebKit Development and jQTouchMobile WebKit Development and jQTouch
Mobile WebKit Development and jQTouch
 
Accelerometer and OpenGL
Accelerometer and OpenGLAccelerometer and OpenGL
Accelerometer and OpenGL
 
Deep Geek Diving into the iPhone OS and Framework
Deep Geek Diving into the iPhone OS and FrameworkDeep Geek Diving into the iPhone OS and Framework
Deep Geek Diving into the iPhone OS and Framework
 
NSNotificationCenter vs. AppDelegate
NSNotificationCenter vs. AppDelegateNSNotificationCenter vs. AppDelegate
NSNotificationCenter vs. AppDelegate
 
Using SQLite
Using SQLiteUsing SQLite
Using SQLite
 
From Flash to iPhone
From Flash to iPhoneFrom Flash to iPhone
From Flash to iPhone
 

Recently uploaded

The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Visualising and forecasting stocks using Dash
Visualising and forecasting stocks using DashVisualising and forecasting stocks using Dash
Visualising and forecasting stocks using Dashnarutouzumaki53779
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterMydbops
 
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your Queries
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your QueriesExploring ChatGPT Prompt Hacks To Maximally Optimise Your Queries
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your QueriesSanjay Willie
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Scott Andery
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 

Recently uploaded (20)

The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Visualising and forecasting stocks using Dash
Visualising and forecasting stocks using DashVisualising and forecasting stocks using Dash
Visualising and forecasting stocks using Dash
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL Router
 
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your Queries
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your QueriesExploring ChatGPT Prompt Hacks To Maximally Optimise Your Queries
Exploring ChatGPT Prompt Hacks To Maximally Optimise Your Queries
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 

Physics Solutions for Innovative Game Design

  • 1. Physics Solutions for Innovative Game Design Give your iPhone games a dynamic real-world feel by integrating a physics engine. Andrei Gradinari Lead Engineer - Backflip Studios Tom Blind Lead Designer - Backflip Studios
  • 2. History of Physics in Games and "Physics Games"
  • 3. History of Physics in Games Very simple physics (Late 80-s to Early 90-s) - Racing games, flight sims, mini golf games, etc ...
  • 4. History of Physics in Games Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half- Life, many others
  • 5. History of Physics in Games Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half- Life, many others
  • 6. History of Physics in Games Simple real physics (Middle - Late 90-s) - NFS 1, Unreal, Half- Life, many others
  • 7. History of Physics in Games Complex real physics (Early 2000s) - Half-Life 2
  • 8. History of Physics in Games Complex real physics (Early 2000s) - Half-Life 2
  • 9. History of Physics in Games Complex real physics (Early 2000s) - Half-Life 2
  • 10. History of Physics in Games Complex real physics (Early 2000s) - Prey
  • 11. Prey: Flip Gravity Gameplay Mechanic (how to get to the box with candy)
  • 12. Prey: Flip Gravity Gameplay Mechanic (how to get to the box with candy)
  • 13. Prey: Flip Gravity Gameplay Mechanic (how to get to the box with candy)
  • 14. History of Physics in Games Physics on GPUs: Almost real world complexity (Middle to Late 2000's) Crysis engine 3000 Barrels, real time:
  • 15. History of Physics in Games Physics on GPUs: Almost real world complexity (Middle to Late 2000's)
  • 16. What is a Physics Game?
  • 17. What is a Physics Game? These are NOT physics games Even though they use physics Doom 3 Unreal
  • 18. What is a Physics Game? These are physics games! Crayon Physics Fantastic Contraption
  • 20. Physics Engine A physics engine is a set of functions that lets you describe layout of your system of physics objects and then tells you how the state of this system changes over time.
  • 21. Physics Engine Define layout of your system of objects (shapes, positions, masses, dimensions, global gravity vector, etc...)
  • 22. Physics Engine The engine tells you how your system changes over time
  • 23. Physics Simulation The process handled by a physics engine that figures out what happens to the given set of objects over a certain period of time is called physics simulation ->Simulation->
  • 24. Physics Simulation Can be: Not Interactive (user input is not taken in consideration) Interactive (user input affects the simulation). Interactive simulations are used in most games
  • 25. Do you need a physics engine?
  • 26. Do you need a physics engine? Sometimes, it's easier to do it yourself! Less memory & CPU usage Less disk space Less time spent linking libraries Simpler, if you don't need anything fancy
  • 27. Do you need a physics engine? Rolling your own physics: acceleration = force / mass Things get trickier with collisions...
  • 28. The Physics of Paper Toss Forces are one-dimensional Add flick force and wind force to determine landing point Animate to make it look pretty No physics library needed!
  • 30. Typical Physics Engine Consists of: Rigid Body Dynamics Simulation Engine Collision Detection Engine
  • 31. Typical Physics Engine Building blocks of your physics world: Geometric Shapes (describe what your objects look like) Joints (describe how your objects are connected to each other)
  • 32. Typical Physics Engine Simulation Step: Collision contact points generation (collision detection engine) Creating temporary joints based on contact points, and attaching them to respective physics objects Performing actual simulation step (rigid body dynamics engine)
  • 37. Performance Tips and Tricks Keep things simple More objects in your physics simulation = more time spent to simulate the system = lower framerate as a result. Approximate complex volumes with sets of simple volumes Performance gain is well worth it. User will never see the difference, as long as you do it right. It's still fine to render fully detailed models, while simulating simple shapes on the physics side.
  • 38. Performance Tips and Tricks Example of complex volumes approximation. Rendered models:
  • 39. Performance Tips and Tricks Example of complex volumes approximation. Simulated shapes:
  • 40. Performance Tips and Tricks Do not simulate static objects They should never be simulated in Rigid Bodies Dynamics Engine, because they never move. Do not simulate dynamic objects that are stationary at the moment. ODE, for example, automatically does this for you. It is called Auto Disable. Use spatial partitioning Setup collision detection engine to generate as few contact points as possible
  • 41. Performance Tips and Tricks Several small steps vs one large step Several small steps: One large step: More realistic simulation, Less realistic simulation especially when simulating dynamically Better performance changing forces Less problems with objects flying through each other.
  • 42. Performance Tips and Tricks Probable instability problems with simulation and their causes: Large simulation step Large forces applied to bodies Large masses, especially when mixed with small masses High speeds of the objects Fast spinning objects High friction
  • 43. A Brief Comparison of Physics Engines Used on the iPhone 2D 3D Box2D ODE Chipmunk Bullet
  • 44. Comparison of Physics Engines Box2D Optimized for 2D games Works well with cocos2d Used in many iPhone games such as Crayon Physics and Rolando
  • 45. Comparison of Physics Engines Chipmunk Very lightweight Written in pure C Made by the creators of Crayon Ball for the iPhone "Makes you smarter, stronger, and more attractive to the opposite gender!"
  • 46. Comparison of Physics Engines Open Dynamics Engine (ODE) Industry veteran Supports full 3D simulation Fast, even on the iPhone Used in Touchgrind and Ragdoll Blaster
  • 47. Comparison of Physics Engines Bullet Physics Library Highly optimized for many architectures Multi-threaded Third most popular physics library according to survey by Game Developer Magazine (Aug. 2009) Used by Oolong Engine (Kids vs. Zombies, iPhysics)
  • 48. Contemporary physics in games on consoles and PC's = the nearest future of physics in mobile games...