A Survey on Collision Detection Techniques for Virtual Environments

Size: px
Start display at page:

Download "A Survey on Collision Detection Techniques for Virtual Environments"

Transcription

1 A Survey on Collision Detection Techniques for Virtual Environments Mauro Figueiredo 1,2, Luis Marcelino 1, Terrence Fernando 1 1 Centre for Virtual Environments, University of Salford University Road, Salford, UK 2 Escola Superior Tecnologia, Universidade do Algarve Faro Portugal MFiguei@ualg.pt, {L.Marcelino, T.Fernando}@salford.ac.uk Abstract. Collision detection is an important component of many applications in computer graphics applications. In particular, it is a critical question for virtual environments applications, where real time performance is required to provide the feeling of being immerse in a environment that looks and is interactive like a real one. In this paper, we look into current approaches for collision detection that can be used for real time interactive virtual environments where the trajectories of moving objects are not predefined. We also present a taxonomy for classifying different collision detection algorithms. In the end, using collision detection toolkits publicly available, we have performed a set of experiments in order to compare the performance between collision detection algorithms based on axis-aligned, discrete orientation polytopes and oriented bounding boxes. 1. Introduction Fundamental to much of the virtual environment work is, in addition to high-level 3D graphical and multimedia scenes (visual output), is the research on advanced methods of interaction and the development of behavioral models. The user, or rather, the visitor of such virtual worlds must be able to act and behave intuitively, as well as receive expectable natural behavior presented as feedback from the objects in the environment, in a way that he/she has the feeling of direct interaction with his/her application, and not using a computer. The collision detection process plays a very important role for achieving the construction of a realistic virtual world, enabling interaction among virtual objects and assisting in the simulation of their dynamic behavior. In many virtual environments, collision detection allows the virtual representation of the user (e.g. the virtual hand) to interact with other virtual objects. This paper reviews different approaches for finding exact collisions between multiple objects with arbitrary trajectories for virtual environment applications. Recently [Jiménez 01] presented a survey on collision which focus greatly in methods for collision detection that explore the tradeoff between the accuracy in finding collisions and the computational time. In our paper, we concentrate on methods to find exact collisions in real time. We think that this is an important issue in a virtual environment. If we want to provide a realistic feedback of an interactive 3D world it is

2 important to simulate the behavior and the exact interactions between 3D virtual objects. To achieve this goal, it is necessary to use the exact representation of the models geometry. If we consider the case of using only bounding boxes or bounding spheres, for example, as approximate models we can obtain very unrealistic situations of interaction in a virtual environment. Furthermore, in virtual environment applications such as virtual prototyping it involves exact object interactions and control. In this paper, we also propose an extension of the taxonomy presented by [Lin 98]. Lin s classifies the different collision detection techniques according to the model representation. Nevertheless, we have found that most of the current collision detection methods for virtual environment applications are supported by polygonal models and therefore we have found the need to extend her taxonomy in order to compare and classify different approaches for collision detection. This paper is organised as follows. In section 2 it is introduced a taxonomy for classifying different collision detection techniques. In section 3, it is presented different methods used for partitioning the space occupied by objects. In section 4, we show several approaches to decompose 3D models in hierarchies of bounding volumes to speed up the collision detection process. In section 5 we also present some results using public available toolkits. In section 6 conclusions are presented. 2. A Taxonomy for Collision Detection Currently there are many implementations of collision detection schemes. It is important to find a framework that enables us to classify and compare different approaches. [Lin 98] relates collision detection techniques according to its 3D model representation: constructive solid geometry, implicit surfaces, parametric surfaces or polygonal models. We have found that much of the work done in collision detection for virtual environment applications is supported by polygonal models. Then, it is necessary to introduce an additional refinement, extending this classification, in order to unite similar approaches and to compare strengths and weakness of each method. In this way, we present a taxonomy for collision detection algorithms in figure 1, which is used to structure the following sections of this paper. World Spatial Partitioning Representations Bounding Volume Hierarchies Regular Grid Octree Binary Space Partitioning Tree R-Tree Axis- Aligned Bounding Volumes Oriented Bounding Boxes Discrete Orientation Polytopes 3-d Tree Figure 1. A taxonomy for comparing different approaches for collision detection.

3 3. Spatial Partitioning Representations One class of hierarchical data structures used for collision detection are spatial partitioning representations: regular grids, octrees, BSP-trees, k-d trees and R-trees. Spatial subdivisions are a recursive partitioning of the embedding space occupied by objects. In general, spatial partitioning structures are used as a secondary representation for the collision detection process. The main idea behind all space partitioning methods is to exploit spatial coherency. For each object, we check for collision only objects of the neighborhood, eliminating comparisons with those objects that are faraway and therefore cannot be colliding. By dividing the space occupied by 3D objects in the environment, one needs to check for contact between only those pairs of objects that are in the same cells of the decomposition. Using such decompositions in a hierarchical manner, as in octrees, BSPtrees, k-d trees or R-trees, can further speed up the collision detection process. Spatial partitioning representations can be used for the N-body or broad phase problem, as well as, for the pair processing or narrow phase problem of the collision detection process. In the broad phase we want to discard, so many as possible, pairs of objects that do not collide. While in the narrow phase we want to know if two objects are colliding Regular Grids The most basic spatial division of the environment is the uniform grid. The three-dimensional space, which is considered to be a unit cube, is divided into N N N cubic cells of equal volume, building a grid of boxes called voxels (figure 2). Each voxel has a list of the objects occupying that region. Each of the three-dimensional objects of the scene can occupy one or more cells of the grid. In this way, an object can be stored in the list of several voxels and the resulting data structure can be large compared to the input data structure. Figure 2. Partition of a 2D scene by a 4x4 uniform grid. When using regular grids some care must be taken when choosing the number N of divisions considered for each of the coordinate axes. It is always difficult to know which is the optimal number N. This is an important question because N defines the size of the cells. According to [Held 95] experiments this value is typically kept small between 5 to 50. If we choose a large value, then each cell will have a smaller volume and will have a small number of objects, which can be good for the collision detection

4 problem, but on the other hand it will result in large memory usage. If we choose a small value for N, then the size of each cell is larger and we will loose the advantages of using spatial partition techniques. Due to its simplest structure, algorithms based on regular grids are in general very simple and for the collision detection problem an algorithm based on regular grids is straightforward. To find out overlapping objects in the broad phase we need to check only those objects that share the same cells. Uniform grids can also be used in the narrow phase. To find out if two objects are colliding it is necessary to check only those cells that have more than one polygon from different objects. Grids are used in a dynamic environment to find collisions in real time by [Zyda 93]. It is used to find overlapping objects in the broad phase of the collision detection procedure, determining pairs of objects candidates for collision, from the intersection of the bounding volumes of the objects. The testbed scenario used is a very large environment where objects are very small compared to grid cells. In fact, they are so small, that objects are approximated by points. Cells are also large enough so that objects cannot traverse more than one cell per frame. [García-Alonso 94] also uses uniform grids. However, in this case, this structure is used to find exact collisions between 3D objects for the narrow phase. It is used a uniform grid for each object. The bounding volume of each object is partitioned in equal boxes and each voxel has a list of the corresponding overlapping faces of that object. To find if two objects are intersecting, then it finds if there is an interference between the voxels of the corresponding objects. In [Held 95] it is also described an algorithm for collision detection that makes use of a grid with 40x40x40 voxels to represent a scene of three dimensional models. In their work, grids are used in a collision detection algorithm implemented in two-phases. In the first phase, they use the bounding volume of the moving object to find out the intersecting cells. An object can occupy more than one cell. From these overlapping voxels they have a list of triangles from the static environment which are candidates for collision. For each static triangle, from the previous step, if its bounding volume intersects the bounding volume of the flying object, then this triangle is passed to a second phase of the collision detection process. In the second phase, for each triangle of the moving object it is determined the overlapping cells, using its bounding box, and it is intersected with each triangle from the static environment in the list of the overlapping cells. They have implemented this approach and tested it in the determination of exact collisions in a static environment with one moving object. [Held 95] concludes that the collision detection algorithm implemented using regular grids is comparable to the faster approach they have implemented using R-trees. In fact, it is known that in sparse environments, in which the objects are uniformly distributed through the space, the use of regular grids is very effective for finding out pairs of colliding objects [Cohen 95]. In a virtual environment, [Zachmann 00] reports the use of grids for finding pairs of candidate objects for collision, also in the broad phase. In this case, objects can also occupy more than one cell. It is presented an improvement of about eighty percent, when using a grid of voxels, compared to the traditional algorithm for the allpairs test without using a grid. Although, the scenario presented was fairly simple, including one moving object with 20 polygons among five hundred static objects with 52 polygons each.

5 Despite the effective use of uniform grids by several authors, regular grids cannot adapt to the distribution of the objects or primitives in the scene. It treats in the same way, regions of the environment with different degrees of occupancy. It cannot adapt to large, entirely occupied or empty regions of space Octree An octree represents 3D solid objects by a tree defining a recursive subdivision of space [Samet 84, Veenstra 88]. The volume occupied by objects in the environment is partitioned, at each time, into eight axis-aligned subvolumes, using a cubic decomposition. Each cube is marked as empty or occupied by solid objects. The resulting octree is a tree structure of degree eight where each nonleaf node has eight sons. There is also an alternative representation where spheres are used instead of cubes as octant including volumes [Hubbard 93, Tzafestas 96]. We start with a finite unit axis-aligned cubic universe, the root node, which is decomposed into eight smaller axis-aligned cubes called octants, numbered from one to eight (figure 3). These octants are obtained from the split of each coordinate direction in the middle of the original cube. If an octant is completely outside the object, then the corresponding node is labeled as white, which means that this region of space is empty. If an octant is completely inside the object, then the node in the octree structure is labeled as black. In both cases, the recursive procedure on that side of the tree is finished. Leaf nodes are either marked as black or white whether they are occupied by the 3D object or not, respectively. If the octant is partially contained in the object, then the octant is decomposed into eight suboctants, each of them being tested again to determine if it is completely inside or completely outside the object. At this time, the size of the corresponding suboctants is again divided by two. At a node level n the corresponding cube is of size 2 n, where node level zero is the root. This recursive procedure is continued until there isn t any octant partially contained in the object or until a desired level of resolution is achieved defined by the depth of the octree structure. If this is the case, then those octants that are only partially contained in the object are approximated as occupied or unoccupied, black or white, using some criteria. Figure 3-b presents an object enclosed by its octant hierarchy and the corresponding octree representation is shown in figure 3-c. Root z x y (a) (b) (c) Figure 3. (a) Octant labeling; (b) an object octree partitioning and (c) the octree structure for the above 3D model. Many researchers use octrees to represent three-dimensional objects. They have also been used to represent the spatial relationship of geometrical objects, making it

6 relatively simple to determine neighbor objects [Moore 88] and to traverse the volume from front to back for hidden surface removal [Gargantini 93]. The idea behind using octrees for collision detection is to compare for collision only those pairs of objects that share the same cells. In figure 4, it is shown the partition of a 2D scene using the quadtree subdivision, which is the equivalent for 2D of the octree subdivision. In this two-dimensional example, it is considered a new quadtree subdivision if the node has more than five objects. Those pairs of objects that do not have some cell in common cannot be overlapping and should not be considered. Each leaf node, in the octree representation of the scene, has a list of the objects sharing that suboctant which are cross checked pairwise for collision. Figure 4. Spatial partition of a 2D scene using a quadtree subdivision. Octrees recursively partition cubes into axis-aligned octants. At each instance, the objects are assigned to one or more octants and each cell is classified as empty or not empty. Those parts of space where octants are labeled as empty are simply discarded, since no overlapping occurs in those cases. Collisions are checked between all object pairs belonging to a particular cell. In order to find pairs of objects that are intersecting, we start at the unit universe root node and find out which are the cells occupied with more than one object. Then we check for exact collision those objects that share at least one of these cells. The resulting advantage of using an octree structure is that we can discard many pairs of objects and primitives that cannot be colliding, increasing the overall performance of the collision detection process. The hierarchical nature of octrees makes them a good choice because they are also adaptive to the cluttering of the environment. In fact, during the octree construction process, as the subdivision is carried at a node level, if the node contains more than the optimum number of objects, an octal-subdivision is generated. On the other hand, it is also more efficient for representing large areas of the free space. However, there are also some problems. Position of the octants is restricted to be aligned with the coordinate axes and the sizes of the octants are fixed to powers of two. In this way, the size of the octree is dependent of the position and orientation of the object. In some positions of the object, the tree may be compact. While in others the tree can become very large. In fact, the position and orientation of the object, affects the size of the octree, as well as, it can influence the quality of the representation, since it is restricted to the depth of the tree allowed for its implementation. Octree models are approximations of the solid objects which are restricted to the desired depth of the tree

7 structure. On the other hand, representing a complex 3D scene can return in a large octree representation with a quite large depth, requiring a large amount of memory and which results in poor worst-case search time. It is possible to overcome these difficulties using vector octrees [Samet 88], extended octrees [Ayala 85, Brunet 90] or polytrees [Carlbom 85]. These generalizations of an octree structure, allows terminal nodes to contain parts of the solid geometry of the object. In this way, the 3D model can be exactly represented, by the underlying primitives, and also reduce the degree of subdivision making the resulting representation to be more compact. [Hubbard 93, 96] approach for finding collisions in real time is based on a time-critical computing algorithm and on octrees of spheres. A time-critical collision detection implementation finds out collisions between successive more detailed approximations of the 3D objects. It uses different levels of detail to the objects geometry. The collision precision is dependent on the time slot available for the detection process, regarding that the overall performance cannot slow down, in order to maintain the application running interactively. A time-critical collision detection algorithm as different levels of accuracy. [Kitamura 94] algorithm for collision detection uses an octree for each object. To find collisions it traverse the updated octree of the moving objects against the static ones to find intersecting nodes. Only those face pairs found on overlapping octree nodes are then cross checked for intersection. [Smith 95] uses bounding volumes in the broad phase to find out possible colliding objects. For each object that share some overlapping bounding box, using the faces bounding volumes, it is found a list of faces for that object that intersect the overlapping region. If there is more than one list of faces, then it is built a face octree structure for the remaining faces. Each face from the lists of faces are inserted in the octree where the root node is the unit cubic of the scene. To find if there is any exact collision, the face octree is traversed and those faces from different objects that share the same cell are intersected, and a list of intersecting face pairs is built. This implementation was tested with two spheres of varying complexity, from about 200 to 4000 triangles, and with fifteen models of the space shuttle with 528 faces. This approach supported by octrees did find the first intersection between 3D objects interactively. However, real applications do not terminate at the first collision. In fact, after the first collision there will be in the next time steps more collisions, probably of the same objects, in the neighborhood. [Smith 95] compared his approach with better results than the work of [Kitamura 94]. A real time exact collision detection for the narrow phase using spherical octrees was developed by [Tzafestas 96]. In this algorithm, each 3D object is described by an octree structure in its local coordinate system. The decomposition process is done using spheres instead of cubes. At each node, it is inscribed a sphere into the cube of the original cubic octree decomposition. From this consideration, it should be noted that in this case the total volume of the spherical octree representation is larger than an equivalent cubic octree structure. The leaf nodes of the spherical octree structure, point to the list of vertex, edge or faces that the corresponding sphere intersects. The exact collision detection algorithm is done in two steps. In the first step it is found the intersecting spherical octree nodes, determining the candidate faces of each object for collision. In the second step, it is determined exactly the pairs of colliding faces from two objects. This implementation was tested using a virtual scene where fifty was the

8 maximum number of vertices of colliding objects. This is in fact a very simple object scene. It is outlined that as the depth of the spherical octree is increased, the collision detection process has a behaviour that approximates to linear. [Zachmann 00] also implemented an incremental collision detection algorithm for the broad phase using octrees, that makes use of temporal coherence. His concern was in finding an approach of quickly updating the octree in a dynamic environment, when the geometry of an object is changed or when it moves. Some care has to be taken since the octree representation must have to be recomputed, which can be particularly expensive Binary Space Partitioning Tree Binary space partitioning (BSP) is an approach that was initially designed to solve the visible surface determination problem [Fuchs 80, Gaede 98, Naylor 90] and can also be used for partitioning the space. A BSP tree is a binary hierarchy tree that represents a recursive subdivision of the n dimensional universe into homogeneous subregions, using n-1 dimensional hyperplanes. In a BSP-tree, the partitioning of the space is defined by these hyperplanes and therefore is not limited to be axis-aligned. Each subregion is divided independently of preceding subdivisions and of the other subspaces, repeatedly until the number of objects or primitives in each subregion is under a given threshold, τ. In a three-dimensional space, a hyperplane h is a plane defined by the set of points that satisfies the equation ax+ by+ cz = d. 3 It partitions R into two half spaces. Those points in space defined as h + = p R 3 : ax+ by+ cz> d represent the positive or front open halfspace. { } The negative or back open halfspace h is defined by the set of points that satisfies the condition represented as h = { 3 : ax+ by+ cz < d} p R. The BSP tree is stored in a binary structure. The root node t 0 of a BSP tree matches the 3 complete region of the 3-D environment, rt ( 0) =R. In fact, the region covered by the root node is unlimited, but in practice it is considered only the region limited to the bounding volume that covers the 3D models of the scene. To this region it is applied a hyperplane h 0, defining a negative h 0 and a positive h + 0 open halfspaces. Such hyperplane, partitions the original space into two new subregions: r ( t1) = rt ( 0) h and 0 r + ( t1) = rt ( 0) h +, stored in the tree as the left ( 0 t 0. left) and right ( t 0. right) child of t 0. To each of this sub-regions, this procedure can be repeated recursively to construct a binary space partition tree. The intent is to cut space recursively into two halves. Starting with the whole universe, cut it in half and continue with each of the halves. Each internal node t of the binary tree stores a hyperplane h t responsible for the partitioning of the space in two disjoint subregions represented by the descending nodes: left edge corresponding to the negative halfspace and right edge for the positive halfspace. The region rt () represented by each internal node t is defined by the intersection of the open-halfspaces, determined by the hyperplanes associated with the previous nodes on the path from the root to the node t. That is, given a node t i at depth i which is along the path defined by { t,..., 0 t i}, where the subscripts denote depth, then if + t is the left child of ti it defines the region 1 rt ( ) = rt ( ) h otherwise rt ( ) = rt ( ) h. i i i 1 t i 1 i i 1 t i 1

9 If the number of objects or primitives is under some predefined constant τ, then the subspace is no longer partitioned and the node is a leaf of the BSP tree. Each leaf node of a BSP structure corresponds to an unpartitioned region designated as cell and stores references to those objects or primitives that are present in the corresponding region. Figure 5 illustrates the building procedure of a BSP tree a 2 4 c 3 b a 3 d 5 4 f d 5 b c e f e (a) Figure 5. a) Partitioning the 2D space and (b) the corresponding BSP tree. (b) BSP trees are often used to solve problems in computer graphics such as global illumination, shadow generation, ray casting and visibility [Naylor 90, Chin 89, Fussel 90]. They are also used to represent solid models and in information retrieval for finding nearest and farthest neighbours, and performing range queries [Thibault 87, Naylor 90]. A major disadvantage of BSP trees is when used in a dynamic scene. If we want to use a BSP structure for collision detection in dynamic scenes, other approaches must be taken in the design of the tree structure. [Naylor 90] approach to this problem was to build a BSP tree for the static environment and another BSP tree for the moving object. At each frame, the two trees are merged to produce a complete scene. An alternative incremental approach was implemented by [Chrysanthou 92] where the polygons of a moving object, and the nodes they define, are removed from the tree and re-inserted at their new position at each frame. When a polygon is deleted from the tree, then we will get two unconnected trees that are merged incrementally. The complexity of restructuring is claimed to be reduced since any moving polygon is closed to a leaf node after the first deletion. This approach was tested with small moving objects. [Kumar 99] describes an algorithm to deal with dynamic environments by expanding BSP trees for polygons to BSP representations of objects and using separating planes between objects. Three-dimensional scenes are represented as a composition of a set of objects, each of which can be represented, added, deleted and moved independently. The BSP tree of an object stores the corresponding polygons in the leaf nodes and the BSP for the complete scene is built by successive merging operations of objects. When an object is moving there is no need to reconstruct the tree, since this structure is not changed under translation and rotation. It is necessary to update only the geometry information to maintain current positions and orientations. Nevertheless, as it is described, after a number of iterations a number of redundant planes result in the parent object from the motion of an object. This leads to the need of periodically reconstruct the complete BSP tree. The main problem of the BSP approach is that in general it is not possible to avoid that the hyperplanes will not cut objects or polygons. Thus, the size of a BSP tree can get very large.

10 Other disadvantage is that the choice of partitioning planes depend heavily on the current arrangement of objects which is critical for dynamic scenes, as it is the case in virtual environments. One of the main advantages of BSP trees is that they provide simple 3D searching, using simple comparisons involving a sidedness test against the hyperplane cut associated to each of the nodes of a BSP tree representation. A BSP tree is not suitable for objects which change their geometry, since in this case the BSP representation has to be recomputed. Binary space partition trees can adapt well to different data distributions [Gaede 98]. Nevertheless, in general they are not balanced and may have very deep subtrees, which has a negative impact on the tree performance k-d Tree The k-d tree [Bentley 75, Bentley 79, Gaede 98] is a binary space partition tree that represents a recursive partition of the space into subspaces using (d-1) dimensional hyperplanes. These hyperplanes are iso-oriented and their directions alternates among the d possibilities. In the three dimensional space, a 3-d tree is a BSP tree whose splitting hyperplanes are chosen alternately orthogonal to the coordinate axes. The 3-d structure is similar to the BSP tree. The root node is also associated to the universe. The difference is that, in this case, as the hyperplanes are always perpendicular to the coordinate axes, then each node of the tree is associated with a parallelepiped, and implicitly with the set of objects or primitives that intersect that subregion. Each non-leaf node is also associated with a hyperplane. To define the children of a node, we must decide if the hyperplane is orthogonal to the x-, y- or z-axis and the coordinate of the corresponding split. If the number of objects or primitives intersecting a subregion falls below a threshold, τ, then the subspace is not partitioned, and the corresponding node is a leaf in the tree. Each leaf node has a list of objects or primitives that intersect its subregion as in a BSP tree. The 3-d tree structure presents identical properties to BSP trees. In addition, a 3-d tree as a very good depth property, since it is always O(log n ) [Duncan 01], which is important for the performance of the tree structure that is directly related to its depth. [Held 95] presents the implementation of a 3-d tree for exact collision detection in a virtual reality walkthrough application. In his work, he evaluates the resulting collision detection manager in a 3-D world, with one moving object in a static environment. Only the static objects in the environment are represented in the 3-d tree. The implemented collision detection manager finds collisions in two steps. First, it searches, in the leaf nodes of the 3-d tree, for triangles from the scene whose bounding boxes overlap the bounding volume of the moving object. If there is an overlapping between bounding volumes, then in the second step, each triangle from the moving object is passed to the 3-d tree and processed until it reaches the appropriate leaf nodes and it is intersected for an exact collision with the corresponding triangles of the 3D scene. In his implementation, [Held 95] found that better results were achieved with a cutting plane perpendicular to the coordinate axis that minimize the product of the number of triangles in the two resulting subregions. It was also decided to split always at the midpoint of the corresponding parallelepiped length and it was defined a threshold τ = 10.

11 The performance of the collision detection manager implemented with the 3-d tree was always worst when compared to an approach supported in a regular grid representation [Held 95]. A single polygon can belong to more than one partition in a 3-d tree and therefore is stored as many times as the number of regions that it overlaps. Experiments conducted by [Held 95] shows that the number of triangles stored in a 3-d tree can be from three to eight times more than the original number of triangles for 3D objects models. Testing scenarios used different objects, with a number of triangles changing from 100 to quite complex ones with about On average the number of triangles stored in a 3-d tree is five times more than the original number of triangles. On the other hand, the 3-d structure requires two times more triangles stored than the correspondent uniform grid structure. Besides, to find exact collisions, the implementation based on the 3-d tree required ten times more nodes visits than the approach based on the regular grid R-Tree Another hierarchical data structure used to represent a partition of the space is the R-tree [Guttman 84, Beckmann 90]. The main idea is to partition the set of objects or primitives associated with a node, as it is shown in figure 6, rather than partitioning the subregion associated with a node, as is done in a BSP or a 3-d tree Root (a) 3 Figure 6. (a) A 2D scene of a set polygons partitioned in a R-tree. (b) The corresponding R-tree for the 2D scene shown above. A R-tree is a multi-ary tree in which the non-leaf node has between τ and σ children, except for the root node. The values τ and σ ( σ 2) τ are the minimum and maximum number of children of a node, respectively. The root node has at least two children unless it is a leaf. The root node is associated to the space covered by all the objects or primitives in the environment. Each node of the tree defines a subregion represented by the bounding volume that encloses the corresponding primitives of its child nodes. If the number of primitives of a node is between τ and σ, then the node is a leaf, and the corresponding primitives are stored on that leaf node. Otherwise, the node is split and the child nodes will then represent their respective subsets of the objects or primitives. Subregions of different nodes can overlap in a R-tree. This means that a spatial query may often require the visit of several nodes to find out overlapping bounding volumes. (b)

12 When building an R-tree, each object is inserted at a leaf node. The appropriate leaf node is found by traversing the R-tree from the root and at each internal node choosing the subtree whose covering bounding volume has to be enlarged the least. Once the leaf node is found, then it is necessary to see if the insertion will cause the node to overflow. If this is the case, then it must be split and the σ + 1 primitives are divided between two nodes. This split is then propagated up the tree. Some important properties of R-tree can be underlined. At any level of the tree, each primitive is associated with only a single node. It is also interesting to note that in a R- tree all leaf nodes appear on the same level. The depth of a R-tree storing n primitives is O(log n/log τ ). The total number of primitives stored in a R-tree equals the number of original primitives. On the contrary, as it was discussed in section 3.4, in a BSP tree the number of stored primitives can be much greater than the original number of primitives. To find collisions of a moving object in a virtual environment, [Held 95] implemented a binary R-tree to represent the static scenario. From their experiments they have concluded that the R-tree was the best approach for finding exact collisions in walkthroughs, when compared to regular grids and 3-d trees. In the R-tree implemented it was defined a threshold τ = 1. In this way, leaf nodes were chosen to have only one triangle. Internal nodes were split using the median x-, y-, or z-coordinate of the centroids of the primitives associated to that node. The corresponding primitives were associated to one of the two sons of the split according to how the centroids fall with respect to the median value. We conclude this section with the Table 1 that summarizes the main properties of the different spatial partitioning techniques for the collision detection problem. 4. Bounding Volumes Hierarchies Many different approaches based on bounding volumes hierarchies have been used to speed up collision detection algorithms in the broad and narrow phases between general polygonal models. The basic idea of these approaches is to approximate the threedimensional models with bounding volumes to reduce the number of pairs of objects or primitives that is needed to be checked for contact. These methods cannot find out if two 3D models are intersecting, but they can be used to quickly reject objects or pairs of polygons which cannot intersect. There are many types of bounding volumes: axis-aligned bounding boxes, spheres, oriented bounding boxes and discrete orientation polytopes Axis-Aligned Boxes and Spheres Typical examples of bounding volumes used in collision detection algorithms for virtual environments are axis-aligned boxes [Van Der Bergen 98] and spheres [Hubbard 96, Palmer 95, Quilan 94]. An axis-aligned bounding box (AABB) is a parallelepiped whose faces are aligned with the coordinate axes. It is very simple to compute an AABB since it is represented with the minimal and maximal values along each axis, specifying a region R limited by the planes parallel to the axes specified by the values: x min, x max, y min, y max, z min, z max. This requires six parameters to specify an axis-aligned bounding box. A bounding sphere is defined with four parameters describing its center point C and radius r, specifying the bounded region.

13 Table 1. Advantages and disadvantages of the spatial partitioning representations. Type of Advantages/Disadvantages Representation Regular Grids Simple algorithms. Improved performance of about 80% [Zachman 00] compared to the traditional n-body problem. Unadapted to the environment distribution of 3D objects. Number of stored primitives greater than the original. Octrees Hierarchy structure. Adaptive to the object distribution. Position and size of octants is restricted. Size of the octree is dependent of the position and orientation of 3D models. Requires large amount of memory. BSP Hierarchy structure. Simple 3D searching algorithms. Adapt well to the environment distribution. Hyperplanes cut objects and polygons. Hyperplanes depend on the scene. Number of stored primitives greater than the original. A BSP tree can get very large. In general the BSP tree is unbalanced. Not suitable for objects that changes its geometry. 3-d Tree Same as BSP trees. Good depth property. Number of stored primitives is about three to eight times more than the original [Held 95]. Worst performance compared to regular grids [Held 95]. A 3-d structure requires two times more stored primitives than the regular grid. The collision detection algorithm implemented with the 3-d tree required to traverse ten times more nodes than the approach based on the regular grid. R-Tree Hierarchy structure. Each primitive is associated with only a single node. All leaf nodes are on the same level. The number of primitives stored equals the number of original primitives. A collision detection algorithm supported only with bounding volumes cannot find out accurately if two polyhedral models are intersecting. In fact, bounding volumes can be effectively used to support an algorithm to reject pairs of objects that do not intersect and generate a list of pairs of models candidates for intersection. A further step can be considered and, for each object, a bounding volume tree is built in order to reduce the number of comparisons needed to find out the candidate primitives for intersection between two polytopes. These types of volumes trees have been widely chosen in virtual environments since it is very easy to implement and fast to find collisions between two such volumes. In fact, to find out if two axis-aligned bounding boxes are overlapping only six comparisons are required. It is also possible to say that two AABBs are disjoint, in the best case situation, with only one comparison. Testing two bounding spheres for overlap is also trivial and can be done with only four additions/subtractions and three comparisons. In addition, it is simple to update these volumes as an object rotates and translates. Collision detection algorithms based on bounding volume hierarchies recursively test pairs of bounding volumes for overlap. If they do not intersect, then that recursion branch ends. If they intersect, then the children bounding volumes nodes are tested for

14 overlap. If it has reached a point where two leaf nodes are found to overlap, then to find out if the two models are colliding, we have to intersect the descendant polygons Oriented Bounding Boxes An oriented bounding box (OBB) is also a rectangular bounding box but with an arbitrary orientation so that it encloses the underlying geometry more tightly (figure 7). The representation of an oriented bounding box encodes not only position and widths, as in the case of the axis aligned bounding boxes, but also orientation. a 1 A 1 C a 2 A 2 (a) (b) (c) Figure 7. a) An example of an oriented bounding box in 2D and (b) the corresponding axis-aligned bounding box. c) Definition parameters of an OBB. For the representation of an oriented bounding box A (figure 7-c), fifteen parameters are used to define the center point C, edge half-lengths a 1, a 2, a 3 and an orientation specified as three mutually orthogonal unit vectors A 1, A 2 and A 3, which are the columns of a 3x3 rotation matrix. With these parameters we can define the bounded region of the oriented bounding box RAPID Recent work using oriented bounding boxes was presented by [Gottschalk 00], for the implementation of an algorithm for collision detection that has been made publicly available in a system called RAPID (Rapid and Accurate Polygon Interference Detection). Using a top-down approach, RAPID builds a hierarchical tree of oriented bounding volumes. This tree is constructed as a recursive application of fit-and-split operations. Given a collection of polygons, it fits a bounding volume to them, and then partitions the collection into two groups. To each group, fit a new bounding volume and partition again until all leaf nodes are indivisible. The subdivision rule used in the RAPID system is to split the longest axis of an oriented bounding box with a plane orthogonal to one of its axes. The placement of this splitting plane is chosen to be that of the mean point, µ, of the vertices. Then descending polygons are grouped into subgroups according to which side of the plane their center point lies on. If the longest axis cannot be subdivided, the second longest axis is chosen. Otherwise, the shortest one is used. If the group of polygons cannot be partitioned along any axis by this criterion, then the group is considered indivisible and this procedure ends. The resulting OBB tree built in this way, based on where the median center point lies, is balanced [Gottschalk 00]. The basic approach in RAPID for fitting an OBB aligned with the model is, using covariance methods, to choose first an orientation for the OBB, and then choose a centre and minimal edge lengths that enables it to cover the model. The overall time to build the oriented bounding tree is not an essential issue for virtual environments applications. This is a pre-processing step which does not influence the

15 interactive component of a virtual environment. On the other hand, it is important that the algorithm for the intersection of three-dimensional models, supported by this hierarchical tree of oriented bounding boxes, runs in real time. An algorithm for finding the overlap status of two oriented bounding boxes tests exhaustively all edges of one box for intersection with any of the faces of the other box and vice-versa. If two OBB overlap, then either one completely contains the other or their boundaries overlap. Testing to find if there is contact between the two OBB requires 144 edge-face tests, which each is a 3-by-3 linear system. If they do not touch, then it is necessary to test whether any point in one box is entirely contained in the other box and vice-versa. In practice, it is an expensive test. What RAPID does to overcome this problem is based on the separating axis theorem [Gottschalk 00]. Two disjoint 3D models can always be separated by a plane which is parallel to a face of either object, or parallel to an edge taken from each object. An oriented bounding box has three unique face orientations and three unique edge directions. This leads to fifteen potential separating axes to test, three faces from one OBB, three faces from the other OBB, and nine pairwise combinations of edges. If two oriented bounding boxes are not in contact, then a separating axis exist, and at least one of the fifteen axes mentioned above will be a separating axis. If the polytopes are overlapping, then clearly no separating axis exists. So, testing the fifteen given axes is a sufficient test for determining overlap status of two OBBs. RAPID implemented this effective approach and the worst-case intersection test between two overlapping oriented bounding boxes is done with 252 arithmetic operations of which we have 15 comparisons, 96 additions and subtractions, 117 multiplications and 24 absolute values. The best case input requires 89 arithmetic operations, distributed as one comparison, 39 addition and subtractions, 39 multiplications and 10 absolute values calculations V-COLLIDE V-COLLIDE is a system for interactive collision detection for polygonal models undergoing rigid motion in VRML environments [Hudson 97]. V-COLLIDE is built on top of the RAPID library, where RAPID is a collision detection library based on oriented bounding boxes (OBB). V-COLLIDE does a sweep-and-prune operation for the broad phase using an axis-aligned bounding box (AABB) for each object. In this first level, V-COLLIDE finds all pairs of overlapping bounding boxes eliminating pairs of objects that cannot intersect. Then for each pair of objects, which are potentially in contact, it uses RAPID algorithm for the narrow phase based on oriented bounding boxes to detect collisions. V-COLLIDE does not provide direct access to the triangles of the underlying geometry. Thus, if the application changes part of the object geometry, then it is necessary to destroy the complete object and rebuild it again from scratch Proximity Query Package The PQP library, Proximity Query Package, uses two different type of bounding volumes [Larsen 99]. It uses rectangle swept spheres (RSS) for distance queries and oriented bounding boxes (OBBs) for collision detection. It is also based on RAPID library.

16 4.3. Discrete Orientation Polytopes As defined by [Klosowski 98] discrete orientation polytopes, or k-dops, are bounding volumes that are convex polytopes whose facets are determined by halfspaces whose outward normals come from a small fixed set of k orientations. An axis-aligned bounding box in 3D is an example of a six-dop with orientation vectors determined by the unit vectors ± i, ± j, ± k. An eight-dop in two dimensions is defined by eight fixed normals defined by the orientations at ±45, ±90, ±135 and ±180 degrees. These different types of bounding boxes are illustrated in figure 8. (a) Figure 8. An example in 2D of (a) an oriented bounding box and (b) an eightdop. The work of Klosowski, which is available in the QuickCD toolkit, concentrated in the study of four choices of k-dops: 6-dops, 14-dops, 18-dops and 26-dops for the collision detection problem. Six-dops are in fact axis-aligned bounding boxes and can easily be built as it was explained in the section 4.1. In order to build a 14-dop, for example, it is required to find the minimum and maximum coordinate values of the primitives along each of the seven directions, which were defined by Klosowski by the unit vectors i, j, k, i + j + k, i j + k, i + j k and i j k. That is, a 14-dop uses six halfspaces defining the volume of an axis-aligned bounding box, plus additional eight diagonal halfspaces that are used to cut off as much of the eight corners of an AABB as possible. Consider again the seven directions vectors defined above, which can also be written as the vectors v 1 = (1,0,0 ), v 2 = (0,1,0 ), v = (0,0,1 3 ), v 4 = (1,1,1 ), v 5 = (1, 1,1 ), v 6 = (1,1, 1) and v 7 = (1, 1, 1). To define a 14-dop bounding volume, fourteen parameters are required to define the lower, l i, and upper, u i, coordinate values of the m vertices, P j, of the underlying polygons, projected onto the seven vectors v i. For each direction v i, the lower and upper values can then be determined by the following expressions: v i li = min OP j j = 1.. m, i = 1..7 vi { } { } v i ui = max OP j j = 1.. m, i = 1..7 vi { } { } This values of l i and u i specifies fourteen halfspaces defining a bounding volume for the underlying geometry constructed as an axis-aligned bounding box with its corners cut off. This volume defines the bounded region for the 14-dop as: v 3 i R = P R : li OP ui i = { 1..7} v i (b) (1) (2)

17 This concept can be extended and more directions can be considered. The QuickCD system also implements a 26-dop volume constructed by the union of the defining halfspaces for the 14-dops and 18-dops, using the six halfspaces of an axisaligned bounding box, plus the eight diagonal halfspace that cut off corners and more twelve halfspaces that cut off edges. The 18-dops is reported as the more effective choice of discrete orientation polytopes. The implementation of the collision detection problem in this system is also based on a bounding volume tree, in this case supported by k-dops. Discrete orientation polytopes are very simple to intersect. If we use 18-dops volumes we need to perform only eighteen comparisons. 5. Experimental Tests Our experiments were conducted using collision detection toolkits publicly available that implement different types of bounding volumes hierarchies. We have used QuickCD, that implements discrete orientation and axis-aligned bounding volumes, which is a particular case of a 6-dop. RAPID was also used for testing the implementation of collision detection schemes supported by oriented bounding boxes. Unfortunately, we did not find any publicly available collision detection that implemented any of the spatial partitioning techniques described in section 3 and, therefore, we could not test its practical importance. First, we have compared different types of bounding volumes. We wanted to have an idea about the order of magnitude of the computation time for calculating the worst-case intersection between two bounding volumes. The running experiments were done in two platforms. We have used one AMD Athlon1600+ with 256Mb of memory and one Silicon Graphics ONYX2 with MIPS10000 processors clocked at 250MHz and 4 gigabytes of RAM. Table 2. Intersection times between bounding volumes. Bounding Volume Athlon1600+ Inf. Reality AABB 31 ns 67 ns 18 DOP 78 ns 168 ns OBB 940 ns 800 ns As we can see from Table 2, the axis-aligned bounding box is found to be an order of magnitude faster than the oriented bounding boxes. In fact, in a SGI the AABBs are about twelve times faster than the OBBs. Although, the axis-aligned bounding boxes do not enclose the object geometry so tight, nevertheless they are much faster than the oriented-bounding boxes. It is expected in a collision detection cycle that we will require more bounding boxes checks than oriented-bounding boxes intersections. But, these last ones are very expensive and in the end if a proper hierarchy of bounding volumes is chosen then a collision detection supported by axis-aligned bounding box is effective. For this reason, we understand why axis-aligned bounding box are commonly used for collision detection. In a second step, we also wanted to compare different collision detection toolkits publicly available. To make the experiment results comparable we used similar conditions for all experiments.

18 For the first tests, we have used equal prisms with four thousand triangles each. One of the prisms is static, centered at the origin of the coordinate axis system. The second prism is moving along the x-axis from an initial position until it reaches the origin. In this case, at the initial position, the two objects are separated from each other. At the final position, the two objects are completely overlapping each other. In this path, the number of contacts between triangles change from 509 to In this first experiment, we want to compare the use of axis-aligned bounding volumes, using quickcd configured as 6-dops, against 18-dops bounding volumes, which is reported as the most effective choice for k-dops. Results are presented in figure 9. From figure 9-a), we can see that it is not achieved real time interaction. Nevertheless, we have chosen this working scenario because we have tried first with smaller objects, in terms on number of polygons, and it was not possible to compare the two approaches, since the results were quite similar. However, in more complex worlds we can see that using k-dops is more effective than using axis-aligned bounding volumes. time to collision (ms) AABB 18-dop Number of Contacts (a) Ratios AABB/18-dops 140% 120% 100% 80% 60% 40% 20% Bounding Volumes Triangles 0% Number of Contacts Figure 9. (a) Performance of an AABB approach compared to k-dops. (b) Overhead of an AABB versus 18-dop approach in terms of percentage of bounding volumes and triangles intersection tests. The 18-dops bounding volume intersection checks are more expensive than the simple axis-aligned tests. On the other hand, 18-dops volume are more tight to the underlying geometry. Therefore, it is possible to filter out much more pairs of not colliding bounding volumes and triangles. In the end, this is more important for the collision detection problem. This assumption is confirmed in figure 9-b), where it is presented the relation between the number of intersection tests between bounding volumes and triangles of axis-aligned bounding boxes, in respect to the 18-dops volumes. On average, axis-aligned bounding volumes requires 30% and 47% more bounding volumes and triangles intersection tests, respectively, than the collision detection manager based on 18-dop. We remember that we have used the QuickCD collision detection toolkit for both tests. Therefore, the algorithm for building the hierarchy tree is the same and, in this way, we are comparing only the use of AABBs or 18-dops. Our next experiment was also done with two prisms, with four hundred polygons each, under identical trajectories circumstances of the first test. We have used a simpler scene because we wanted to test the use of oriented bounding boxes or discrete orientation polytopes at interactive rates. (b)

19 Figure 10-a) presents the comparison between RAPID and QuickCD configured with 18-dops volumes. The number of colliding triangles in this path varies from 268 to 380. In this setup the QuickCD collision detection toolkit has better performance than RAPID. In figure 10-b), we can see the ratios of 18-dops versus oriented bounding boxes. It is interesting to see that on average the 18-dops require 83% more bounding volume tests than the oriented bounding volumes. However, we have seen before that the cost of intersecting oriented bounding volumes is about five times more than 18- dops. It is also interesting to see that QuickCD does on average about 800% more triangle intersection tests than RAPID, which is an expensive test. Although, in this case, they can be optimised since the underlying primitives are triangles. But in the end the QuickCD was faster than RAPID. time to collision (ms) Rapid QuickCD Number of Contacts (a) Ratios 18-dops/OBBs 1200% 1000% 800% 600% 400% 200% Bounding Volumes Triangles 0% Number of Contacts (b) Figure 10. (a) Time to find exact collisions using RAPID and QuickCD. (b) Overhead of an 18-dops versus OBBs approach in terms of percentage of bounding volumes and triangles intersection tests. In our last experiment, we have used a real industrial case study from Rolls Royce. A Fuel Metering Unit is moving into an Oil Pump from the Trent 800 engine, along a path where the number of contacts change from 28 to 851. These parts are used in the engine for the Boeing 777. The Fuel Metering Unit is a component tessellated to 5130 triangles and the Oil Pump has triangles. Figure 11 shows the fuel-metering unit and the oil pump. Figure 11. The fuel metering unit and the oil pump. In figure 12 we compare RAPID and QuickCD. In this case, RAPID is faster and at each time step, it requires on average 26ms to find all collisions, against 38ms by QuickCD. From the ratios of 18-dops versus oriented bounding boxes, we can see now that on average the 18-dops require 500% more bounding volume tests and 200% more triangle intersection tests than the oriented bounding volumes.

Spatial Data Structures

Spatial Data Structures CSCI 420 Computer Graphics Lecture 17 Spatial Data Structures Jernej Barbic University of Southern California Hierarchical Bounding Volumes Regular Grids Octrees BSP Trees [Angel Ch. 8] 1 Ray Tracing Acceleration

More information

Collision Detection II. These slides are mainly from Ming Lin s course notes at UNC Chapel Hill

Collision Detection II. These slides are mainly from Ming Lin s course notes at UNC Chapel Hill Collision Detection II These slides are mainly from Ming Lin s course notes at UNC Chapel Hill http://www.cs.unc.edu/~lin/comp259-s06/ Some Possible Approaches Geometric methods Algebraic techniques Hierarchical

More information

Spatial Data Structures

Spatial Data Structures CSCI 480 Computer Graphics Lecture 7 Spatial Data Structures Hierarchical Bounding Volumes Regular Grids BSP Trees [Ch. 0.] March 8, 0 Jernej Barbic University of Southern California http://www-bcf.usc.edu/~jbarbic/cs480-s/

More information

Collision and Proximity Queries

Collision and Proximity Queries Collision and Proximity Queries Dinesh Manocha (based on slides from Ming Lin) COMP790-058 Fall 2013 Geometric Proximity Queries l Given two object, how would you check: If they intersect with each other

More information

Collision Detection based on Spatial Partitioning

Collision Detection based on Spatial Partitioning Simulation in Computer Graphics Collision Detection based on Spatial Partitioning Matthias Teschner Computer Science Department University of Freiburg Outline introduction uniform grid Octree and k-d tree

More information

Spatial Data Structures

Spatial Data Structures 15-462 Computer Graphics I Lecture 17 Spatial Data Structures Hierarchical Bounding Volumes Regular Grids Octrees BSP Trees Constructive Solid Geometry (CSG) April 1, 2003 [Angel 9.10] Frank Pfenning Carnegie

More information

Spatial Data Structures

Spatial Data Structures 15-462 Computer Graphics I Lecture 17 Spatial Data Structures Hierarchical Bounding Volumes Regular Grids Octrees BSP Trees Constructive Solid Geometry (CSG) March 28, 2002 [Angel 8.9] Frank Pfenning Carnegie

More information

Spatial Data Structures

Spatial Data Structures Spatial Data Structures Hierarchical Bounding Volumes Regular Grids Octrees BSP Trees Constructive Solid Geometry (CSG) [Angel 9.10] Outline Ray tracing review what rays matter? Ray tracing speedup faster

More information

Ray Tracing Acceleration Data Structures

Ray Tracing Acceleration Data Structures Ray Tracing Acceleration Data Structures Sumair Ahmed October 29, 2009 Ray Tracing is very time-consuming because of the ray-object intersection calculations. With the brute force method, each ray has

More information

Collision Detection with Bounding Volume Hierarchies

Collision Detection with Bounding Volume Hierarchies Simulation in Computer Graphics Collision Detection with Bounding Volume Hierarchies Matthias Teschner Computer Science Department University of Freiburg Outline introduction bounding volumes BV hierarchies

More information

Intersection Acceleration

Intersection Acceleration Advanced Computer Graphics Intersection Acceleration Matthias Teschner Computer Science Department University of Freiburg Outline introduction bounding volume hierarchies uniform grids kd-trees octrees

More information

Lesson 05. Mid Phase. Collision Detection

Lesson 05. Mid Phase. Collision Detection Lesson 05 Mid Phase Collision Detection Lecture 05 Outline Problem definition and motivations Generic Bounding Volume Hierarchy (BVH) BVH construction, fitting, overlapping Metrics and Tandem traversal

More information

Collision Detection. These slides are mainly from Ming Lin s course notes at UNC Chapel Hill

Collision Detection. These slides are mainly from Ming Lin s course notes at UNC Chapel Hill Collision Detection These slides are mainly from Ming Lin s course notes at UNC Chapel Hill http://www.cs.unc.edu/~lin/comp259-s06/ Computer Animation ILE5030 Computer Animation and Special Effects 2 Haptic

More information

Simulation in Computer Graphics Space Subdivision. Matthias Teschner

Simulation in Computer Graphics Space Subdivision. Matthias Teschner Simulation in Computer Graphics Space Subdivision Matthias Teschner Outline Introduction Uniform grid Octree and k-d tree BSP tree University of Freiburg Computer Science Department 2 Model Partitioning

More information

CPSC / Sonny Chan - University of Calgary. Collision Detection II

CPSC / Sonny Chan - University of Calgary. Collision Detection II CPSC 599.86 / 601.86 Sonny Chan - University of Calgary Collision Detection II Outline Broad phase collision detection: - Problem definition and motivation - Bounding volume hierarchies - Spatial partitioning

More information

Ray Tracing III. Wen-Chieh (Steve) Lin National Chiao-Tung University

Ray Tracing III. Wen-Chieh (Steve) Lin National Chiao-Tung University Ray Tracing III Wen-Chieh (Steve) Lin National Chiao-Tung University Shirley, Fundamentals of Computer Graphics, Chap 10 Doug James CG slides, I-Chen Lin s CG slides Ray-tracing Review For each pixel,

More information

Collision Detection. Motivation - Dynamic Simulation ETH Zurich. Motivation - Path Planning ETH Zurich. Motivation - Biomedical Simulation ETH Zurich

Collision Detection. Motivation - Dynamic Simulation ETH Zurich. Motivation - Path Planning ETH Zurich. Motivation - Biomedical Simulation ETH Zurich Collision Detection Motivation - Dynamic Simulation Collision detection is an essential part of physically realistic dynamic simulations. For each time step: compute dynamics detect collisions resolve

More information

SURFACE COLLISION DETECTION WITH THE OVERLAPPING BOUNDING BOX BETWEEN VIRTUAL PROTOTYPE MODELS

SURFACE COLLISION DETECTION WITH THE OVERLAPPING BOUNDING BOX BETWEEN VIRTUAL PROTOTYPE MODELS International Conference on Advanced Research in Virtual and Rapid Prototyping SURFACE COLLISION DETECTION WITH THE OVERLAPPING BOUNDING BOX BETWEEN VIRTUAL PROTOTYPE MODELS Mauro Figueiredo 1,2, Terrence

More information

COLLISION DETECTION FOR VIRTUAL PROTOTYPING ENVIRONMENTS

COLLISION DETECTION FOR VIRTUAL PROTOTYPING ENVIRONMENTS XIII ADM - XV INGEGRAF International Conference on TOOLS AND METHODS EVOLUTION IN ENGINEERING DESIGN Cassino, June 3th, 2003 Napoli, June 4 th and June 6 th, 2003 Salerno, June 5 th, 2003 COLLISION DETECTION

More information

Using Bounding Volume Hierarchies Efficient Collision Detection for Several Hundreds of Objects

Using Bounding Volume Hierarchies Efficient Collision Detection for Several Hundreds of Objects Part 7: Collision Detection Virtuelle Realität Wintersemester 2007/08 Prof. Bernhard Jung Overview Bounding Volumes Separating Axis Theorem Using Bounding Volume Hierarchies Efficient Collision Detection

More information

Advanced 3D-Data Structures

Advanced 3D-Data Structures Advanced 3D-Data Structures Eduard Gröller, Martin Haidacher Institute of Computer Graphics and Algorithms Vienna University of Technology Motivation For different data sources and applications different

More information

Announcements. Written Assignment2 is out, due March 8 Graded Programming Assignment2 next Tuesday

Announcements. Written Assignment2 is out, due March 8 Graded Programming Assignment2 next Tuesday Announcements Written Assignment2 is out, due March 8 Graded Programming Assignment2 next Tuesday 1 Spatial Data Structures Hierarchical Bounding Volumes Grids Octrees BSP Trees 11/7/02 Speeding Up Computations

More information

Lecture 25 of 41. Spatial Sorting: Binary Space Partitioning Quadtrees & Octrees

Lecture 25 of 41. Spatial Sorting: Binary Space Partitioning Quadtrees & Octrees Spatial Sorting: Binary Space Partitioning Quadtrees & Octrees William H. Hsu Department of Computing and Information Sciences, KSU KSOL course pages: http://bit.ly/hgvxlh / http://bit.ly/evizre Public

More information

Accelerated Raytracing

Accelerated Raytracing Accelerated Raytracing Why is Acceleration Important? Vanilla ray tracing is really slow! mxm pixels, kxk supersampling, n primitives, average ray path length of d, l lights, 2 recursive ray casts per

More information

Recall: Inside Triangle Test

Recall: Inside Triangle Test 1/45 Recall: Inside Triangle Test 2D Bounding Boxes rasterize( vert v[3] ) { bbox b; bound3(v, b); line l0, l1, l2; makeline(v[0],v[1],l2); makeline(v[1],v[2],l0); makeline(v[2],v[0],l1); for( y=b.ymin;

More information

Overview. Collision detection. Collision detection. Brute force collision detection. Brute force collision detection. Motivation

Overview. Collision detection. Collision detection. Brute force collision detection. Brute force collision detection. Motivation Overview Collision detection Alan Liu aliu@simcen.usuhs.mil Surgical Simulation Laboratory National Capital Area Medical Simulation Center Uniformed Services University of the Health Sciences http://simcen.usuhs.mil/mmvr2002

More information

CSG obj. oper3. obj1 obj2 obj3. obj5. obj4

CSG obj. oper3. obj1 obj2 obj3. obj5. obj4 Solid Modeling Solid: Boundary + Interior Volume occupied by geometry Solid representation schemes Constructive Solid Geometry (CSG) Boundary representations (B-reps) Space-partition representations Operations

More information

CS535 Fall Department of Computer Science Purdue University

CS535 Fall Department of Computer Science Purdue University Spatial Data Structures and Hierarchies CS535 Fall 2010 Daniel G Aliaga Daniel G. Aliaga Department of Computer Science Purdue University Spatial Data Structures Store geometric information Organize geometric

More information

Lecture 17: Solid Modeling.... a cubit on the one side, and a cubit on the other side Exodus 26:13

Lecture 17: Solid Modeling.... a cubit on the one side, and a cubit on the other side Exodus 26:13 Lecture 17: Solid Modeling... a cubit on the one side, and a cubit on the other side Exodus 26:13 Who is on the LORD's side? Exodus 32:26 1. Solid Representations A solid is a 3-dimensional shape with

More information

Bounding Volume Hierarchies

Bounding Volume Hierarchies Tutorial: Real-Time Collision Detection for Dynamic Virtual Environments Bounding Volume Hierarchies Stefan Kimmerle WSI/GRIS University of Tübingen Outline Introduction Bounding Volume Types Hierarchy

More information

Spatial Data Structures and Speed-Up Techniques. Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology

Spatial Data Structures and Speed-Up Techniques. Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology Spatial Data Structures and Speed-Up Techniques Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology Spatial data structures What is it? Data structure that organizes

More information

Solid Modeling. Thomas Funkhouser Princeton University C0S 426, Fall Represent solid interiors of objects

Solid Modeling. Thomas Funkhouser Princeton University C0S 426, Fall Represent solid interiors of objects Solid Modeling Thomas Funkhouser Princeton University C0S 426, Fall 2000 Solid Modeling Represent solid interiors of objects Surface may not be described explicitly Visible Human (National Library of Medicine)

More information

Overview. Collision Detection. A Simple Collision Detection Algorithm. Collision Detection in a Dynamic Environment. Query Types.

Overview. Collision Detection. A Simple Collision Detection Algorithm. Collision Detection in a Dynamic Environment. Query Types. Overview Collision Detection Alan Liu aliu@usuhs.mil The Surgical Simulation Laboratory National Capital Area Medical Simulation Center Uniformed Services University http://simcen.usuhs.mil/miccai2003

More information

CMSC 754 Computational Geometry 1

CMSC 754 Computational Geometry 1 CMSC 754 Computational Geometry 1 David M. Mount Department of Computer Science University of Maryland Fall 2005 1 Copyright, David M. Mount, 2005, Dept. of Computer Science, University of Maryland, College

More information

Homework 1: Implicit Surfaces, Collision Detection, & Volumetric Data Structures. Loop Subdivision. Loop Subdivision. Questions/Comments?

Homework 1: Implicit Surfaces, Collision Detection, & Volumetric Data Structures. Loop Subdivision. Loop Subdivision. Questions/Comments? Homework 1: Questions/Comments? Implicit Surfaces,, & Volumetric Data Structures Loop Subdivision Shirley, Fundamentals of Computer Graphics Loop Subdivision SIGGRAPH 2000 course notes Subdivision for

More information

Computer Graphics Ray Casting. Matthias Teschner

Computer Graphics Ray Casting. Matthias Teschner Computer Graphics Ray Casting Matthias Teschner Outline Context Implicit surfaces Parametric surfaces Combined objects Triangles Axis-aligned boxes Iso-surfaces in grids Summary University of Freiburg

More information

improving raytracing speed

improving raytracing speed ray tracing II computer graphics ray tracing II 2006 fabio pellacini 1 improving raytracing speed computer graphics ray tracing II 2006 fabio pellacini 2 raytracing computational complexity ray-scene intersection

More information

Collision Detection. Jane Li Assistant Professor Mechanical Engineering & Robotics Engineering

Collision Detection. Jane Li Assistant Professor Mechanical Engineering & Robotics Engineering RBE 550 MOTION PLANNING BASED ON DR. DMITRY BERENSON S RBE 550 Collision Detection Jane Li Assistant Professor Mechanical Engineering & Robotics Engineering http://users.wpi.edu/~zli11 Euler Angle RBE

More information

CAB: Fast Update of OBB Trees for Collision Detection between Articulated Bodies

CAB: Fast Update of OBB Trees for Collision Detection between Articulated Bodies CAB: Fast Update of OBB Trees for Collision Detection between Articulated Bodies Harald Schmidl Nolan Walker Ming C. Lin {schmidl walkern lin}@cs.unc.edu Department of Computer Science Sitterson Hall,

More information

Spatial Data Structures and Acceleration Algorithms

Spatial Data Structures and Acceleration Algorithms Spatial Data Structures and Acceleration Algorithms Real-time Renderg Performance Goals Spatial Structures Boundg Volume Hierarchies (BVH) Bary Space Partiong(BSP) Trees, Octrees Scene Graphs Cullg Techniques

More information

Solid Modelling. Graphics Systems / Computer Graphics and Interfaces COLLEGE OF ENGINEERING UNIVERSITY OF PORTO

Solid Modelling. Graphics Systems / Computer Graphics and Interfaces COLLEGE OF ENGINEERING UNIVERSITY OF PORTO Solid Modelling Graphics Systems / Computer Graphics and Interfaces 1 Solid Modelling In 2D, one set 2D line segments or curves does not necessarily form a closed area. In 3D, a collection of surfaces

More information

Chapter 11 Global Illumination. Part 1 Ray Tracing. Reading: Angel s Interactive Computer Graphics (6 th ed.) Sections 11.1, 11.2, 11.

Chapter 11 Global Illumination. Part 1 Ray Tracing. Reading: Angel s Interactive Computer Graphics (6 th ed.) Sections 11.1, 11.2, 11. Chapter 11 Global Illumination Part 1 Ray Tracing Reading: Angel s Interactive Computer Graphics (6 th ed.) Sections 11.1, 11.2, 11.3 CG(U), Chap.11 Part 1:Ray Tracing 1 Can pipeline graphics renders images

More information

Hidden Surface Elimination: BSP trees

Hidden Surface Elimination: BSP trees Hidden Surface Elimination: BSP trees Outline Binary space partition (BSP) trees Polygon-aligned 1 BSP Trees Basic idea: Preprocess geometric primitives in scene to build a spatial data structure such

More information

Ray Tracing: Intersection

Ray Tracing: Intersection Computer Graphics as Virtual Photography Ray Tracing: Intersection Photography: real scene camera (captures light) photo processing Photographic print processing Computer Graphics: 3D models camera tone

More information

Acceleration Data Structures

Acceleration Data Structures CT4510: Computer Graphics Acceleration Data Structures BOCHANG MOON Ray Tracing Procedure for Ray Tracing: For each pixel Generate a primary ray (with depth 0) While (depth < d) { Find the closest intersection

More information

Computer Graphics. - Spatial Index Structures - Philipp Slusallek

Computer Graphics. - Spatial Index Structures - Philipp Slusallek Computer Graphics - Spatial Index Structures - Philipp Slusallek Overview Last lecture Overview of ray tracing Ray-primitive intersections Today Acceleration structures Bounding Volume Hierarchies (BVH)

More information

Implicit Surfaces & Solid Representations COS 426

Implicit Surfaces & Solid Representations COS 426 Implicit Surfaces & Solid Representations COS 426 3D Object Representations Desirable properties of an object representation Easy to acquire Accurate Concise Intuitive editing Efficient editing Efficient

More information

Speeding Up Ray Tracing. Optimisations. Ray Tracing Acceleration

Speeding Up Ray Tracing. Optimisations. Ray Tracing Acceleration Speeding Up Ray Tracing nthony Steed 1999, eline Loscos 2005, Jan Kautz 2007-2009 Optimisations Limit the number of rays Make the ray test faster for shadow rays the main drain on resources if there are

More information

Dynamic Collision Detection

Dynamic Collision Detection Distance Computation Between Non-Convex Polyhedra June 17, 2002 Applications Dynamic Collision Detection Applications Dynamic Collision Detection Evaluating Safety Tolerances Applications Dynamic Collision

More information

Scene Management. Video Game Technologies 11498: MSc in Computer Science and Engineering 11156: MSc in Game Design and Development

Scene Management. Video Game Technologies 11498: MSc in Computer Science and Engineering 11156: MSc in Game Design and Development Video Game Technologies 11498: MSc in Computer Science and Engineering 11156: MSc in Game Design and Development Chap. 5 Scene Management Overview Scene Management vs Rendering This chapter is about rendering

More information

Anti-aliased and accelerated ray tracing. University of Texas at Austin CS384G - Computer Graphics Fall 2010 Don Fussell

Anti-aliased and accelerated ray tracing. University of Texas at Austin CS384G - Computer Graphics Fall 2010 Don Fussell Anti-aliased and accelerated ray tracing University of Texas at Austin CS384G - Computer Graphics Fall 2010 Don Fussell Reading Required: Watt, sections 12.5.3 12.5.4, 14.7 Further reading: A. Glassner.

More information

Spatial data structures in 2D

Spatial data structures in 2D Spatial data structures in 2D 1998-2016 Josef Pelikán CGG MFF UK Praha pepca@cgg.mff.cuni.cz http://cgg.mff.cuni.cz/~pepca/ Spatial2D 2016 Josef Pelikán, http://cgg.mff.cuni.cz/~pepca 1 / 34 Application

More information

An iterative, octree-based algorithm for distance computation between polyhedra with complex surfaces 1

An iterative, octree-based algorithm for distance computation between polyhedra with complex surfaces 1 An iterative, octree-based algorithm for distance computation between polyhedra with complex surfaces 1 André Borrmann, Stefanie Schraufstetter, Christoph van Treeck, Ernst Rank {borrmann, schraufstetter,

More information

Ray Tracing with Spatial Hierarchies. Jeff Mahovsky & Brian Wyvill CSC 305

Ray Tracing with Spatial Hierarchies. Jeff Mahovsky & Brian Wyvill CSC 305 Ray Tracing with Spatial Hierarchies Jeff Mahovsky & Brian Wyvill CSC 305 Ray Tracing Flexible, accurate, high-quality rendering Slow Simplest ray tracer: Test every ray against every object in the scene

More information

CMSC 425: Lecture 10 Geometric Data Structures for Games: Index Structures Tuesday, Feb 26, 2013

CMSC 425: Lecture 10 Geometric Data Structures for Games: Index Structures Tuesday, Feb 26, 2013 CMSC 2: Lecture 10 Geometric Data Structures for Games: Index Structures Tuesday, Feb 2, 201 Reading: Some of today s materials can be found in Foundations of Multidimensional and Metric Data Structures,

More information

Geometric Algorithms. Geometric search: overview. 1D Range Search. 1D Range Search Implementations

Geometric Algorithms. Geometric search: overview. 1D Range Search. 1D Range Search Implementations Geometric search: overview Geometric Algorithms Types of data:, lines, planes, polygons, circles,... This lecture: sets of N objects. Range searching Quadtrees, 2D trees, kd trees Intersections of geometric

More information

Computer Graphics. Bing-Yu Chen National Taiwan University The University of Tokyo

Computer Graphics. Bing-Yu Chen National Taiwan University The University of Tokyo Computer Graphics Bing-Yu Chen National Taiwan University The University of Tokyo Hidden-Surface Removal Back-Face Culling The Depth-Sort Algorithm Binary Space-Partitioning Trees The z-buffer Algorithm

More information

The BSP tree identifying the object has all the constituent polygons at the leaf nodes. We use the variant BSP described above[11]. The Binary Space P

The BSP tree identifying the object has all the constituent polygons at the leaf nodes. We use the variant BSP described above[11]. The Binary Space P Efficient Object BSP Trees Navendu Jain, Sorav Bansal, Sanjiv Kapoor Computer Science and Engineering Department, Block VI, Indian Institute of Technology, Hauz Khas, New Delhi 110016, India. Email: skapoor@cse.iitd.ernet.in

More information

Comparing Sphere-Tree Generators and Hierarchy Updates for Deformable Objects Collision Detection

Comparing Sphere-Tree Generators and Hierarchy Updates for Deformable Objects Collision Detection Comparing Sphere-Tree Generators and Hierarchy Updates for Deformable Objects Collision Detection M. Garcia, S. Bayona, P. Toharia, and C. Mendoza Universidad Rey Juan Carlos, c/tulipan s/n E-28933 Mostoles

More information

Nearest Neighbors Classifiers

Nearest Neighbors Classifiers Nearest Neighbors Classifiers Raúl Rojas Freie Universität Berlin July 2014 In pattern recognition we want to analyze data sets of many different types (pictures, vectors of health symptoms, audio streams,

More information

1. Meshes. D7013E Lecture 14

1. Meshes. D7013E Lecture 14 D7013E Lecture 14 Quadtrees Mesh Generation 1. Meshes Input: Components in the form of disjoint polygonal objects Integer coordinates, 0, 45, 90, or 135 angles Output: A triangular mesh Conforming: A triangle

More information

Advanced Ray Tracing

Advanced Ray Tracing Advanced Ray Tracing Thanks to Fredo Durand and Barb Cutler The Ray Tree Ni surface normal Ri reflected ray Li shadow ray Ti transmitted (refracted) ray 51 MIT EECS 6.837, Cutler and Durand 1 Ray Tree

More information

On the data structures and algorithms for contact detection in granular media (DEM) V. Ogarko, May 2010, P2C course

On the data structures and algorithms for contact detection in granular media (DEM) V. Ogarko, May 2010, P2C course On the data structures and algorithms for contact detection in granular media (DEM) V. Ogarko, May 2010, P2C course Discrete element method (DEM) Single particle Challenges: -performance O(N) (with low

More information

Ray-tracing Acceleration. Acceleration Data Structures for Ray Tracing. Shadows. Shadows & Light Sources. Antialiasing Supersampling.

Ray-tracing Acceleration. Acceleration Data Structures for Ray Tracing. Shadows. Shadows & Light Sources. Antialiasing Supersampling. Ray-tracing Acceleration Acceleration Data Structures for Ray Tracing Thanks to Fredo Durand and Barb Cutler Soft shadows Antialiasing (getting rid of jaggies) Glossy reflection Motion blur Depth of field

More information

Spatial Data Structures for Computer Graphics

Spatial Data Structures for Computer Graphics Spatial Data Structures for Computer Graphics Page 1 of 65 http://www.cse.iitb.ac.in/ sharat November 2008 Spatial Data Structures for Computer Graphics Page 1 of 65 http://www.cse.iitb.ac.in/ sharat November

More information

Collision Detection. Pu Jiantao.

Collision Detection. Pu Jiantao. Collision Detection Pu Jiantao. 12-09 Content Introduction CD with rays Dynamic CD using BSP Trees Hierarchical Method OBBTree Method Some Other Topics 12-1717 2 Introduction Collision Collision is a fundamental

More information

Accelerating Geometric Queries. Computer Graphics CMU /15-662, Fall 2016

Accelerating Geometric Queries. Computer Graphics CMU /15-662, Fall 2016 Accelerating Geometric Queries Computer Graphics CMU 15-462/15-662, Fall 2016 Geometric modeling and geometric queries p What point on the mesh is closest to p? What point on the mesh is closest to p?

More information

Last Time: Acceleration Data Structures for Ray Tracing. Schedule. Today. Shadows & Light Sources. Shadows

Last Time: Acceleration Data Structures for Ray Tracing. Schedule. Today. Shadows & Light Sources. Shadows Last Time: Acceleration Data Structures for Ray Tracing Modeling Transformations Illumination (Shading) Viewing Transformation (Perspective / Orthographic) Clipping Projection (to Screen Space) Scan Conversion

More information

Parallel Physically Based Path-tracing and Shading Part 3 of 2. CIS565 Fall 2012 University of Pennsylvania by Yining Karl Li

Parallel Physically Based Path-tracing and Shading Part 3 of 2. CIS565 Fall 2012 University of Pennsylvania by Yining Karl Li Parallel Physically Based Path-tracing and Shading Part 3 of 2 CIS565 Fall 202 University of Pennsylvania by Yining Karl Li Jim Scott 2009 Spatial cceleration Structures: KD-Trees *Some portions of these

More information

COMP 175: Computer Graphics April 11, 2018

COMP 175: Computer Graphics April 11, 2018 Lecture n+1: Recursive Ray Tracer2: Advanced Techniques and Data Structures COMP 175: Computer Graphics April 11, 2018 1/49 Review } Ray Intersect (Assignment 4): questions / comments? } Review of Recursive

More information

Universiteit Leiden Computer Science

Universiteit Leiden Computer Science Universiteit Leiden Computer Science Optimizing octree updates for visibility determination on dynamic scenes Name: Hans Wortel Student-no: 0607940 Date: 28/07/2011 1st supervisor: Dr. Michael Lew 2nd

More information

Lecture 11: Ray tracing (cont.)

Lecture 11: Ray tracing (cont.) Interactive Computer Graphics Ray tracing - Summary Lecture 11: Ray tracing (cont.) Graphics Lecture 10: Slide 1 Some slides adopted from H. Pfister, Harvard Graphics Lecture 10: Slide 2 Ray tracing -

More information

Page 1. Area-Subdivision Algorithms z-buffer Algorithm List Priority Algorithms BSP (Binary Space Partitioning Tree) Scan-line Algorithms

Page 1. Area-Subdivision Algorithms z-buffer Algorithm List Priority Algorithms BSP (Binary Space Partitioning Tree) Scan-line Algorithms Visible Surface Determination Visibility Culling Area-Subdivision Algorithms z-buffer Algorithm List Priority Algorithms BSP (Binary Space Partitioning Tree) Scan-line Algorithms Divide-and-conquer strategy:

More information

Spatial Data Structures and Acceleration Algorithms

Spatial Data Structures and Acceleration Algorithms Spatial Data Structures and Acceleration Algorithms Real-time Rendering Performance Goals Spatial Structures Bounding Volume Hierarchies (BVH) Binary Space Partioning(BSP) Trees, Octrees Scene Graphs Culling

More information

Computing Visibility. Backface Culling for General Visibility. One More Trick with Planes. BSP Trees Ray Casting Depth Buffering Quiz

Computing Visibility. Backface Culling for General Visibility. One More Trick with Planes. BSP Trees Ray Casting Depth Buffering Quiz Computing Visibility BSP Trees Ray Casting Depth Buffering Quiz Power of Plane Equations We ve gotten a lot of mileage out of one simple equation. Basis for D outcode-clipping Basis for plane-at-a-time

More information

Technical Section. Tribox bounds for three-dimensional objects

Technical Section. Tribox bounds for three-dimensional objects PERGAMON Computers & Graphics 23 (1999) 429-437 Technical Section Tribox bounds for three-dimensional objects A. Crosnier a, *, J.R. Rossignac b a LIMM, 161 rue Ada, 34392 Montpellier Cedex 5, France b

More information

CS 563 Advanced Topics in Computer Graphics Culling and Acceleration Techniques Part 1 by Mark Vessella

CS 563 Advanced Topics in Computer Graphics Culling and Acceleration Techniques Part 1 by Mark Vessella CS 563 Advanced Topics in Computer Graphics Culling and Acceleration Techniques Part 1 by Mark Vessella Introduction Acceleration Techniques Spatial Data Structures Culling Outline for the Night Bounding

More information

Ray Tracing. Cornell CS4620/5620 Fall 2012 Lecture Kavita Bala 1 (with previous instructors James/Marschner)

Ray Tracing. Cornell CS4620/5620 Fall 2012 Lecture Kavita Bala 1 (with previous instructors James/Marschner) CS4620/5620: Lecture 37 Ray Tracing 1 Announcements Review session Tuesday 7-9, Phillips 101 Posted notes on slerp and perspective-correct texturing Prelim on Thu in B17 at 7:30pm 2 Basic ray tracing Basic

More information

In the previous presentation, Erik Sintorn presented methods for practically constructing a DAG structure from a voxel data set.

In the previous presentation, Erik Sintorn presented methods for practically constructing a DAG structure from a voxel data set. 1 In the previous presentation, Erik Sintorn presented methods for practically constructing a DAG structure from a voxel data set. This presentation presents how such a DAG structure can be accessed immediately

More information

Real-Time Collision Detection for Dynamic Virtual Environments

Real-Time Collision Detection for Dynamic Virtual Environments Real-Time Collision Detection for Dynamic Virtual Environments Gabriel Zachmann, Matthias Teschner, Stefan Kimmerle, Bruno Heidelberger, Laks Raghupathi, Arnulph Fuhrmann To cite this version: Gabriel

More information

Computer Graphics. - Ray-Tracing II - Hendrik Lensch. Computer Graphics WS07/08 Ray Tracing II

Computer Graphics. - Ray-Tracing II - Hendrik Lensch. Computer Graphics WS07/08 Ray Tracing II Computer Graphics - Ray-Tracing II - Hendrik Lensch Overview Last lecture Ray tracing I Basic ray tracing What is possible? Recursive ray tracing algorithm Intersection computations Today Advanced acceleration

More information

Point Cloud Filtering using Ray Casting by Eric Jensen 2012 The Basic Methodology

Point Cloud Filtering using Ray Casting by Eric Jensen 2012 The Basic Methodology Point Cloud Filtering using Ray Casting by Eric Jensen 01 The Basic Methodology Ray tracing in standard graphics study is a method of following the path of a photon from the light source to the camera,

More information

Computer Graphics (CS 543) Lecture 13b Ray Tracing (Part 1) Prof Emmanuel Agu. Computer Science Dept. Worcester Polytechnic Institute (WPI)

Computer Graphics (CS 543) Lecture 13b Ray Tracing (Part 1) Prof Emmanuel Agu. Computer Science Dept. Worcester Polytechnic Institute (WPI) Computer Graphics (CS 543) Lecture 13b Ray Tracing (Part 1) Prof Emmanuel Agu Computer Science Dept. Worcester Polytechnic Institute (WPI) Raytracing Global illumination-based rendering method Simulates

More information

Two Optimization Methods for Raytracing. W. Sturzlinger and R. F. Tobler

Two Optimization Methods for Raytracing. W. Sturzlinger and R. F. Tobler Two Optimization Methods for Raytracing by W. Sturzlinger and R. F. Tobler Johannes Kepler University of Linz Institute for Computer Science Department for graphical and parallel Processing Altenbergerstrae

More information

Data Mining. Part 2. Data Understanding and Preparation. 2.4 Data Transformation. Spring Instructor: Dr. Masoud Yaghini. Data Transformation

Data Mining. Part 2. Data Understanding and Preparation. 2.4 Data Transformation. Spring Instructor: Dr. Masoud Yaghini. Data Transformation Data Mining Part 2. Data Understanding and Preparation 2.4 Spring 2010 Instructor: Dr. Masoud Yaghini Outline Introduction Normalization Attribute Construction Aggregation Attribute Subset Selection Discretization

More information

L1 - Introduction. Contents. Introduction of CAD/CAM system Components of CAD/CAM systems Basic concepts of graphics programming

L1 - Introduction. Contents. Introduction of CAD/CAM system Components of CAD/CAM systems Basic concepts of graphics programming L1 - Introduction Contents Introduction of CAD/CAM system Components of CAD/CAM systems Basic concepts of graphics programming 1 Definitions Computer-Aided Design (CAD) The technology concerned with the

More information

Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology

Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology A tool needed for the graphics people all the time Very important components: Need to make them fast! Finding if

More information

Spatial Data Structures. Steve Rotenberg CSE168: Rendering Algorithms UCSD, Spring 2017

Spatial Data Structures. Steve Rotenberg CSE168: Rendering Algorithms UCSD, Spring 2017 Spatial Data Structures Steve Rotenberg CSE168: Rendering Algorithms UCSD, Spring 2017 Ray Intersections We can roughly estimate the time to render an image as being proportional to the number of ray-triangle

More information

Spatial Data Structures and Speed-Up Techniques. Ulf Assarsson Department of Computer Science and Engineering Chalmers University of Technology

Spatial Data Structures and Speed-Up Techniques. Ulf Assarsson Department of Computer Science and Engineering Chalmers University of Technology Spatial Data Structures and Speed-Up Techniques Ulf Assarsson Department of Computer Science and Engineering Chalmers University of Technology Exercises l Create a function (by writing code on paper) that

More information

Clipping & Culling. Lecture 11 Spring Trivial Rejection Outcode Clipping Plane-at-a-time Clipping Backface Culling

Clipping & Culling. Lecture 11 Spring Trivial Rejection Outcode Clipping Plane-at-a-time Clipping Backface Culling Clipping & Culling Trivial Rejection Outcode Clipping Plane-at-a-time Clipping Backface Culling Lecture 11 Spring 2015 What is Clipping? Clipping is a procedure for spatially partitioning geometric primitives,

More information

Today. Acceleration Data Structures for Ray Tracing. Cool results from Assignment 2. Last Week: Questions? Schedule

Today. Acceleration Data Structures for Ray Tracing. Cool results from Assignment 2. Last Week: Questions? Schedule Today Acceleration Data Structures for Ray Tracing Cool results from Assignment 2 Last Week: koi seantek Ray Tracing Shadows Reflection Refraction Local Illumination Bidirectional Reflectance Distribution

More information

l Without collision detection (CD), it is practically impossible to construct e.g., games, movie production tools (e.g., Avatar)

l Without collision detection (CD), it is practically impossible to construct e.g., games, movie production tools (e.g., Avatar) Collision Detection Originally created by Tomas Akenine-Möller Updated by Ulf Assarsson Department of Computer Engineering Chalmers University of Technology Introduction l Without collision detection (CD),

More information

Ray Tracing. Foley & Van Dam, Chapters 15 and 16

Ray Tracing. Foley & Van Dam, Chapters 15 and 16 Ray Tracing Foley & Van Dam, Chapters 15 and 16 Ray Tracing Visible Surface Ray Tracing (Ray Casting) Examples Efficiency Issues Computing Boolean Set Operations Recursive Ray Tracing Determine visibility

More information

9. Visible-Surface Detection Methods

9. Visible-Surface Detection Methods 9. Visible-Surface Detection Methods More information about Modelling and Perspective Viewing: Before going to visible surface detection, we first review and discuss the followings: 1. Modelling Transformation:

More information

Lecture 3: Art Gallery Problems and Polygon Triangulation

Lecture 3: Art Gallery Problems and Polygon Triangulation EECS 396/496: Computational Geometry Fall 2017 Lecture 3: Art Gallery Problems and Polygon Triangulation Lecturer: Huck Bennett In this lecture, we study the problem of guarding an art gallery (specified

More information

Ray Tracing Foley & Van Dam, Chapters 15 and 16

Ray Tracing Foley & Van Dam, Chapters 15 and 16 Foley & Van Dam, Chapters 15 and 16 (Ray Casting) Examples Efficiency Issues Computing Boolean Set Operations Recursive Determine visibility of a surface by tracing rays of light from the viewer s eye

More information

Efficient Collision Detection Using Bounding Volume Hierarchies of k-dops Λ

Efficient Collision Detection Using Bounding Volume Hierarchies of k-dops Λ Efficient Collision Detection Using Bounding Volume Hierarchies of k-dops Λ James T. Klosowski y Martin Held z Joseph S.B. Mitchell x Henry Sowizral Karel Zikan k Abstract Collision detection is of paramount

More information

3D Representation and Solid Modeling

3D Representation and Solid Modeling MCS 585/480 Computer Graphics I 3D Representation and Solid Modeling Week 8, Lecture 16 William Regli and Maxim Peysakhov Geometric and Intelligent Computing Laboratory Department of Computer Science Drexel

More information

VIII. Visibility algorithms (II)

VIII. Visibility algorithms (II) VIII. Visibility algorithms (II) Hybrid algorithsms: priority list algorithms Find the object visibility Combine the operations in object space (examples: comparisons and object partitioning) with operations

More information

Efficient Collision Detection Using a Dual Bounding Volume Hierarchy

Efficient Collision Detection Using a Dual Bounding Volume Hierarchy Efficient Collision Detection Using a Dual Bounding Volume Hierarchy Jung-Woo Chang 1, Wenping Wang 2, and Myung-Soo Kim 1 1 Seoul National University, Korea 2 University of Hong Kong, Hong Kong Abstract.

More information