2.1. Collision Detection Overview.

Slides:



Advertisements
Similar presentations
2.6. B OUNDING V OLUME H IERARCHIES Overview of different forms of bounding volume hierarchy.
Advertisements

2.3. B OUNDING V OLUMES Bounding volumes of use for collision detection.
Chapter 4.2 Collision Detection and Resolution. 2 Collision Detection Complicated for two reasons 1. Geometry is typically very complex, potentially requiring.
Collision Detection CSCE /60 What is Collision Detection?  Given two geometric objects, determine if they overlap.  Typically, at least one of.
Collision Detection and Resolution Zhi Yuan Course: Introduction to Game Development 11/28/
3.2. I NTRODUCTION TO R EAL - TIME P HYSICS Overview of core principles behind real-time physics systems.
3.7. S TABILITY AND O PTIMISATION Improving engine stability and performance.
2.1. C OLLISION D ETECTION Overview. Collision detection is used within many types of application, e.g. from robotics, through engineering simulations,
CSE 380 – Computer Game Programming Collision Detection & Response Erin Catto’s Box2D.
Week 14 - Monday.  What did we talk about last time?  Bounding volume/bounding volume intersections.
4.11. T REES AND V EGETATION Rendering of trees and vegetation.
Collision Detection CSE 191A: Seminar on Video Game Programming Lecture 3: Collision Detection UCSD, Spring, 2003 Instructor: Steve Rotenberg.
Chapter 4.2 Collision Detection and Resolution. 2 Collision Detection Complicated for two reasons 1. Geometry is typically very complex, potentially requiring.
Parallel Decomposition-based Contact Response Fehmi Cirak California Institute of Technology.
1 Geometry A line in 3D space is represented by  S is a point on the line, and V is the direction along which the line runs  Any point P on the line.
Adapted from: CULLIDE: Interactive Collision Detection Between Complex Models in Large Environments using Graphics Hardware Naga K. Govindaraju, Stephane.
Implicit Surfaces Tom Ouyang January 29, Outline Properties of Implicit Surfaces Polygonization Ways of generating implicit surfaces Applications.
Oct 26, Fall 2006IAT 4101 Collision Detection. Oct 26, Fall 2006IAT 4102 Collision Detection  Essential for many games –Shooting –Kicking, punching,
Game Mathematics & Game State The Complexity of Games Expectations of Players Efficiency Game Mathematics o Collision Detection & Response o Object Overlap.
Oct 3, Fall 2005Game Design1 Collision Detection.
University of Texas at Austin CS 378 – Game Technology Don Fussell CS 378: Computer Game Technology 3D Engines and Scene Graphs Spring 2012.
Computer graphics & visualization Collision Detection – Narrow Phase.
12/4/2001CS 638, Fall 2001 Today Using separating planes/axes for collision testing Collision detection packages.
Modeling and representation 1 – comparative review and polygon mesh models 2.1 Introduction 2.2 Polygonal representation of three-dimensional objects 2.3.
Graphics Graphics Korea University cgvr.korea.ac.kr Creating Virtual World I 김 창 헌 Department of Computer Science Korea University
COMPUTER AIDED DESIGN -(CAD)-3
CSE 381 – Advanced Game Programming Quickhull and GJK.
3D Graphics for Game Programming Chapter XII Physics-based Simulation.
3.4. C ONTACT G ENERATION Generating contacts between rigid bodies.
CO1301: Games Concepts Dr Nick Mitchell (Room CM 226) Material originally prepared by Gareth Bellaby.
Collision/Acceleration University of British Columbia CPSC 314 Computer Graphics Jan-Apr 2013 Tamara Munzner.
12/4/2001CS 638, Fall 2001 Today Managing large numbers of objects Some special cases.
PRESENTED BY – GAURANGI TILAK SHASHANK AGARWAL Collision Detection.
Collision and Proximity Queries Dinesh Manocha Department of Computer Science University of North Carolina
CIS 350 – I Game Programming Instructor: Rolf Lakaemper.
Visual Computing Geometric Modelling 1 INFO410 & INFO350 S2 2015
A Computationally Efficient Framework for Modeling Soft Body Impact Sarah F. Frisken and Ronald N. Perry Mitsubishi Electric Research Laboratories.
Minimum Distance between curved surfaces Li Yajuan Oct.25,2006.
CSCE 552 Spring D Models By Jijun Tang. Triangles Fundamental primitive of pipelines  Everything else constructed from them  (except lines and.
Advanced Computer Graphics Spring 2014 K. H. Ko School of Mechatronics Gwangju Institute of Science and Technology.
Advanced Games Development Game Physics CO2301 Games Development 1 Week 19.
Interactive Continuous Collision Detection for Polygon Soups Xin Huang 11/20/2007.
Introduction to Game Programming & Design III Lecture III.
3D Object Representations 2009, Fall. Introduction What is CG?  Imaging : Representing 2D images  Modeling : Representing 3D objects  Rendering : Constructing.
Finite element mesh and load definition
Core mathematical underpinnings
CS679 - Fall Copyright Univ. of Wisconsin
POLYGON MESH Advance Computer Graphics
Computer Animation Ying Zhu Georgia State University
Collision Detection Spring 2004.
Introduction to Graphics Modeling
3D Object Representations
CS475 3D Game Development Level Of Detail Nodes (LOD)
3.7. Other Game Physics Approaches
Parts of these slides are based on
Graceful Degradation Of Collision Handling in Physically Based Animation John Dingliana , Carol O’ Sullivan.
Chapter 4.2 Collision Detection and Resolution
2.5. Basic Primitive Intersection
Relational Algebra Chapter 4, Sections 4.1 – 4.2
Chapter III Modeling.
Prepared by: Engr . Syed Atir Iftikhar
Motion in Real and Virtual Worlds
Computer Animation Algorithms and Techniques
Collision Detection.
Advanced Games Development Game Physics
CO Games Concepts Week 12 Collision Detection
Games Development Game Architecture: Entities
Use of particle effects within games
Rendering of trees and vegetation
GPAT – Chapter 7 Physics.
Presentation transcript:

2.1. Collision Detection Overview

Note: The material in this section is based on the course text. Introduction to Collision Detection Collision detection is used within many types of application, e.g. from robotics, through engineering simulations, to computer games. In computer games, collision detection provides: the illusion of a solid world (e.g. preventing the player from falling through the floor, rag-dolls from visually intersecting their surroundings) line-of-sight queries (e.g. for driving AI opponent visibility/aiming tests, etc.). The following considers a number of key design issues to consider when building a collision detection system.

Collision Detection Design Issues Core issues for consideration when building a collision detection system

Key design issues: Object Representation Game object representations include: Explicit representation: e.g. polygon (triangle) mesh consisting of a number of defined vertices, connected by edges and forming faces. Most game objects are represented (and rendered) using a triangle mesh. Implicit representation: e.g. Spheres, ellipsoids, cylinders, whose surface is defined mathematically . Aside: Some objects can be precisely defined both explicitly and implicitly, e.g. cuboids.

Key design issues: Object Representation Typically an explicit mesh used for rendering will be too complex (hence computationally expensive) to be used for collision detection. An implicit object description or simple explicit representation can be employed as an object approximation. This is effective as 1) we are very tolerant of minor inaccuracies between collision detection (particularly if the objects are moving quickly or there are many on- screen collisions) , 2) in games there is rarely a need for very high precision. The downside of using separate collision geometry is data duplication (more information needs to be stored) and the extra work required to build and maintain the collision geometry.

Key design issues: Collision Query Type Common types of collision query include (in all cases assumed between two objects based on their current positions/orientations) Determining (i.e. true/false response) if two objects are intersecting (broadly easy/fast to accomplish) Determining the point(s) of contact between two objects. The point(s) of contact might be expressed in terms of a penetration depth, surface normal, etc. Aside: Often a rigid-body physics simulation will need to consider the set of all contacting points between two bodies (i.e. the contact manifold). Computing the contact manifold is typically a complex problem.

Key design issues: Environmental Parameters The number of potentially intersecting objects and their spatial organisation will likely have a bearing upon how a collision detection system is introduced. For large numbers of items an exhaustive set of pairwise tests becomes impractical (n(n-1)/2 individual tests). The number of tested pairs needs to be reduced. This is typically done by separating collision detection into two phases: Broad phase – identifying (small) subgroups of objects that may be colliding Narrow phase – Pairwise collision tests between objects contained within subgroups

Key design issues: Sequential vs. Simultaneous Motion All objects are stepped (i.e. position/rotation updated) by a small time step (e.g. 1/50s). A set of all intersecting objects is determined and processed (e.g. the set of intersecting objects can respond in a physically plausible manner) Sequential Motion: Each object is moved and immediately tested for collision (alongside collision resolution). Then the next object is given an opportunity to move. Sequential movement is the more physically inaccurate approach (e.g. resulting in collisions that should not have occurred).

Key design issues: Discrete vs. Continuous Motion Discrete Motion: This involves checking for intersection between objects at discrete time instances. At each point, the objects are considered to be stationary. Continuous Motion: This involves considering the continuous motion of the object over the specified period of time (i.e. its swept volume). Continuous motion intersection is often a lot more expensive than discrete motion, but can determine the exact point of initial contact and is not subject to tunnelling. Aside: Tunnelling can be a problem with discrete motion if, within the time step between intersections, an object moves more than its spatial extent (i.e. it may simply through another object without detection).

Key design issues: Performance Intersection detection is typically an expensive test. Means of improving performance include: Selecting a board-phase approach that exploits object spatial distribution. Performing simple bounding volume tests first, before considering more complex/accurate geometric intersection tests. Exploiting temporal coherency, i.e. in general the position/orientation of objects change slowly from one frame to the next (often permitting results to be cached and reused). Of course there are a range of lower-level, implementation and platform specific optimisations that can be considered if needed.

Directed reading Directed Reading Directed collision overview reading

Directed reading Directed reading Read Chapter 2 (pp7-21) of Real Time Collision Detection

To do: Summary Explore the directed reading. Today we explored: Overview of collision detection issues. Common types of collision detection system. To do: Explore the directed reading.