3D Collision Detection: a Survey
Total Page:16
File Type:pdf, Size:1020Kb
D Collision Detection A Survey P Jimenez F Thomas and C Torras Institut de Robotica i Informatica Industrial CSICUPCGran Capita Ed 1 Nexus Barcelona SPAIN Abstract Many applications in Computer Graphics require fast and robust D collision detec tion algorithms These algorithms can b e group ed into four approaches spacetime volume intersection swept volume interference multiple interference detection and tra jectory parameterization While some approaches are linked to a particular ob ject representation scheme eg spacetime volume intersection is particularly suited to a CSG representation others do not The multiple interference detection approach has b een the most widely used under a variety of sampling strategies reducing the collision detection problem to multiple calls to static interference tests In most cases these tests b oil down to detecting intersections b etween simple geometric entities such as spheres b oxes aligned with the co ordinate axes or p olygons and segments The computational cost of a collision detection algorithm dep ends not only on the complexity of the basic interference test used but also on the numb er of times this test is applied Therefore it is crucial to apply this test only at those instants and places where a collision can truly o ccur Several strategies have b een develop ed to this end to nd a lower time b ound for the rst collision to reduce the pairs of primitives within ob jects susceptible of interfering and to cut down the numb er of ob ject pairs to b e considered for interference These strategies rely on distance computation algorithms hierarchical ob ject representations orientation based pruning criteria and space partitioning schemes This pap er tries to provide a comprehensive survey of all these techniques from a unied viewp oint so that wellknown algorithms are presented as particular in stances of general approaches Key words Geometric algorithms languages and systems Collision Detection Interference Tests 1 Email fjimenezthomastorrasgiriup ces Preprint submitted to Elsevier Preprint April Intro duction Many collision detection algorithms have b een prop osed in recent years within the elds of Computational Geometry Rob otics and esp ecially Computer Graphics Some app ear tailored to particular applications others stem from theoretical concerns and their diverse origins and aims often hide the common ground on which they lie This article tries to unravel this common ground A recent survey on the sub ject classies collision detection algorithms according to the geometric ob ject mo del used The present pap er is rather oriented towards a systematic characterization of the solving strategies as explained b elow The reader interested in a quick comparison of the most wellknown algorithms can have a lo ok at the table in httpbrleewashingtoneduBRLshccollidehtm Computer Graphics encompasses a broad set of applications related to ComputerAided Design Virtual Reality and Physical Simulation that require fast collision detection The algorithms develop ed in this context are ab ove all intended to b e of practical use Con trarily the eld of Computational Geometry seeks to synthesize algorithms with the b est p ossible worstcase complexity which in many cases entails the design of intrincate data structures Thus while computational geometers and graphicists have a substantial over lap of interest in geometry their algorithms ob ey markedly dierent purp oses Computational geometry algorithms often assume general p osition but realworld mo d els tend to have a lot of degeneracies such as coplanar or parallel faces Thus any assump tion of general p osition is inappropriate in practical settings Not only degeneracies but also bad data lead to challenging problems For example as noted in p olyhedral mo dels generated by some widely used CAD systems tend to have various degrees of nearly coplanar vertices ie p olygonal faces b ounded by four or more vertices where the vertices only approximately lie on the same plane And even worse many mo dels tend to have selfintersections ie they contain faces which intersect at places other than their b oundaries As a consequence practical collision detection algorithms are shap ed not only by the application itself but also by the challenging inputs arising in practice The application largely delimits the kind of algorithms to b e applied For example while the path taken by the moving ob ject in Virtual Reality applications is not known a pri ori precisely sp ecied tra jectories have to b e checked for collision in rigid b o dy physical simulation systems that involve the exact repro duction of mechanical pro cesses Thus a tra jectorybased approach suitable in the latter case would b e useless in the former one Moreover when the application allows it and for eciencys sake a collision detec tion algorithm might delib erately intro duce error For example ob jects might b e crudely approximated by cub es spheres p olyspheres etc and complex tra jectories decomp osed into simpler ones or simply discretized Practical collision detection algorithms have long sought to exploit this tradeo b etween solution quality and computational time We de vote an imp ortant part of this survey to these approximations The pap er is structured as follows Section II shows that the available collision detection approaches lie within two main categories geometric and algebraic and explains how those based on the former category apply two techniques pro jection and sampling or combinations of them This overview makes clear that tests for static interference b etween simple geometric entities lie at the base of most detection approaches Section III presents these tests The eciency of a basic interference test do es not guarantee that a collision detection algorithm based on it is in turn ecient b ecause the numb er of times the test is applied is another key factor Thus Section IV reviews the dierent strategies to restrict the application of the interference test to those instants time b ounds and ob ject parts space b ounds at which a collision can truly o ccur Finally conclusions are sketched in Section V Approaches to collision detection Collision detection admits several problem formulations dep ending on the typ e of output sought and on the constraints imp osed on the inputs The simplest decisional problem that lo oking for a yesno answer is usually stated as follows Given a set of ob jects and a description of their motions over a certain time span determine whether any pair will come into contact More intricate versions require nding the time and features involved in the collision Placing constraints on the inputs is a usual way of simplifying problems Thus often ob jects are assumed to b e p olyhedra usually convex ones and motions are constrained to b e translational or linear in a given parameter space In the following subsections the four main approaches that have b een prop osed to deal with the dierent instances of the collision detection problem are describ ed Spatiotemporal intersection The most general representation of the collision detection problem is based on the extru sion op eration The extruded volume of an ob ject is the spatiotemp oral set of p oints representing the spatial o ccupancy of the ob ject along its tra jectory A collision b etween 2 two ob jects o ccurs if and only if their extruded volumes intersect see Figs and The extrusion op eration is distributive with resp ect to the union intersection and set dif ference op erations This motivated the development of the extrusion approach in the con text of Constructive Solid Geometry CSG representations The mentioned distributive prop erty guarantees that an ob ject and its extruded volume can b e represented through the same b o olean combination of volumetric primitives and extrusions of these primitives resp ectively The formal b eauty of this approach is partially o ccluded by the high cost of its practical implementation whose b ottleneck is the generation of the D extruded volumes them selves Thus for example the extrusion of a linear subspace sub ject to a constant angular velo city is b ounded by a helicoidal hyp ersurface For this reason the implementation deals only with linear subspaces sub ject to piecewise translational motions 2 Almost all gures that illustrate the dierent issues in the text represent the corresp onding D situation for clarity t y x y x Fig Extruded and Swept Volumes Time is explicitly taken into account Since the extruded volumes interfere a col lision is detected Below the corresponding swept volumes in D are shown t y x y x Fig Extruded and Swept Volumes cont Here no col lision takes place and therefore the extruded volumes do not interfere Note that the corresponding swept volumes in D are the same as those in the previous gure If the computation of the extruded volumes in D were simple no other approaches would have b een intro duced since they are all aimed at avoiding this explicit computation These approaches are either geometric or algebraic Among the geometric ones two main alternatives have b een prop osed namely pro jecting the extruded volume onto a lower dimensional subspace which leads to the swept volume approach and sampling along the tra jectory which b oils down to the rep eated application of an intersection detection algorithm The algebraic approach consists of parameterizing the tra jectory Next we describ e these approaches Swept volume interference The volume containing all the p oints o ccupied by a moving ob ject during