OBBTree - PowerPoint PPT Presentation

1 / 49
About This Presentation
Title:

OBBTree

Description:

New hierarchical representation for OBB models. Fast overlap test for two OBBs ... Coarse tessellation. Have to traverse entire hierarchies. No advantages for OBBs ... – PowerPoint PPT presentation

Number of Views:121
Avg rating:3.0/5.0
Slides: 50
Provided by: kabyj
Category:

less

Transcript and Presenter's Notes

Title: OBBTree


1
OBBTree
  • Han, Gabjong
  • hkj84_at_postech.ac.kr
  • POSTECH VR Lab
  • 2006. 4. 12.

2
Outline
  • Introduction
  • Previous Methods
  • Hierarchical Methods
  • Other Approaches
  • Previous OBB Methods
  • OBBTree Building
  • Overlap Test for OBBs
  • OBB vs. Other Volumes
  • Implementation and Performance
  • Robustness and Accuracy
  • Performance
  • Comparison with Others
  • RAPID
  • Cost Evaluation
  • Conclusion

3
Introduction - Concepts
  • What is collision detection?
  • Checks whether two objects overlap in space
  • What is proximity?
  • Information about the relative configuration of
    two objects

4
Introduction - Concepts
  • What is OBB?
  • Synonym for oriented bounding box
  • Rectangular bounding box at an arbitrary
    orientation in 3D space

OBB
AABB
5
Introduction - Problems
  • Problems in collision detection
  • Model Complexity
  • Unstructured Representation
  • Close Proximity
  • Accurate Contact Determination

6
Introduction - Contributions
  • OBBTree Contributions
  • New hierarchical representation for OBB models
  • Fast overlap test for two OBBs
  • Comparison with other representations
  • Robust and interactive implementation and
    demonstration

7
Hierarchical Methods
  • Simplest algorithms in collision detection
  • Problems in hierarchical methods
  • Poor performance in extreme cases
  • Close proximity
  • Multiple contacts

8
Hierarchical Methods - Examples
  • Examples
  • Bounding volumes
  • AABBs and Spheres
  • Hierarchical structures
  • Cone trees, k-d trees and octrees
  • Sphere trees, R-trees
  • Spatial representations
  • BSP and multi-space partitions
  • Space-time bounds or four-dimensional testing

9
Other Approaches
  • Theoretically efficient algorithms
  • Problems of this kind
  • Unclear practical utility
  • Limited models
  • Limited motion
  • Slow performance

10
Previous OBB Methods
  • Used to speed up ray-tracing and other
    interference computation
  • Issues in OBBs
  • Computing tight-fitting OBBs
  • Testing two boxes for overlap

11
Previous OBB Methods- Tight-fitting Issues
  • Minimal enclosing box algorithm
  • O(n3)
  • Simple Incremental algorithm
  • O(n), but constant factor is very high
  • Using Hierarchical model
  • Cannot be applied for large unstructured models

12
Previous OBB Methods- Overlap Test Issues
  • Edge by edge intersection test
  • Linear programming algorithm
  • General purpose test

13
OBBTree Building OBB Data Structure
  • Midpoint
  • C
  • 3 basis vectors
  • bu, bv, bw
  • 3 half-dimensions
  • hu, hv, hw

14
OBBTree Building Covariance Matrix
  • What is covariance matrix?
  • A matrix of covariances between elements of a
    vector

15
OBBTree Building
  • How to get the midpoint of OBB?
  • Assume the centroid of all polygons as midpoint
  • How to get the orientation of OBB?
  • Using the covariance matrix
  • Eigenvectors of the matrix is basis

16
OBBTree Building- Simple Approach
  • Triangulate all polygons
  • Obtain the centroid with all triangles
  • Compute the covariance matrix
  • Get the basis using the eigenvectors of the
    matrix
  • Compute maximum and minimum extents
  • Get the center and the half-dimensions of the OBB

17
OBBTree Building
  • Problem with Simple Approach
  • Sampling problem
  • Interior vertices
  • Dense collection of vertices
  • Solution
  • Using a convex hull
  • Integrating over the surface of each triangle

18
OBBTree Building - Building Steps of OBB
  • Triangulate all polygons
  • Compute the convex hull (added)
  • Calculate the centroid (revised)
  • Compute the covariance matrix (revised)
  • Get the eigenvectors
  • Compute the extreme veritces
  • Take the points

19
OBBTree Building
  • Triangulate all polygons
  • Compute the convex hull

20
OBBTree Building
  • Calculate the centroid
  • The area of a triangle
  • The centroid of the triangle
  • c (pqr) /3
  • The centroid of the entire convex hull

21
OBBTree Building
  • Compute the covariance matrix
  • Get the eigenvectors
  • Covariance matrix is diagonalizable

22
OBBTree Building
  • Compute the extreme vertices along each axis
  • Take the points
  • A midpoint is the mean of extreme values
  • A half-dimension value is distance between the
    midpoint and one extreme value

23
OBBTree Building - Method
  • Top down methods of OBBTree Building

24
OBBTree Building
  • Building steps of OBBTree
  • Begin with a group of all polygons
  • Subdivide recursively until all leaf nodes are
    indivisible
  • Subdivision rule
  • Split longest axis to shortest one until it can
    split

25
Overlap Test for OBBs - Concepts
  • Separating axis theorem
  • Two convex polytopes are disjoint iff there exist
    a separating axis orthogonal to a face of either
    polytope or orthogonal to an edge from each
    polytope

26
Overlap Test for OBBs
  • Separating axis test for two boxes
  • T distance between center of A and B
  • L separating axis
  • Ai half-dimension
  • ai basis vector

27
Overlap Test for OBBs
  • Possible separating axis
  • Face to face, face to edge, face to vertex
  • Each face can be a separating plane
  • Edge to edge
  • Two edges can create one plane
  • Vertex to vertex, edge to vertex
  • They can be expressed by other plane

28
Overlap Test for OBBs
  • Each box has three unique face normals and three
    unique edges
  • 3 faces 3 faces
  • 3 edges 3 edges
  • 15 candidates for a separating axis

29
Overlap Test for OBBs
  • Projection intervals are disjoint iff
  • Simplifed computation example

30
Overlap Test for OBBs
  • Degenerate OBBs
  • An OBB become a rectangle or a line segment
  • Much simpler test

31
Overlap Test for OBBs
  • OBBs with infinite extents
  • One term should be removed by one infinity
    condition
  • if a2 is infinite,

32
Overlap Test for OBBs
  • Performance of overlap testing algorithms
  • Two previous algorithms are optimized for general
    convex polytopes
  • All these algorithms are much faster than 144
    edge-face tests
  • New algorithm is about 10 times faster than
    previous algorithms

33
OBB vs. Other Volumes
  • What is Hausdorff distance?
  • distance from set A to set B is a maximin
    function, defined as

34
OBB vs. Other Volumes
  • Tightness
  • Diameter
  • Aspect ratio

35
OBB vs. Other Volumes Analytical Performance
Comparison
  • Aspect ratio and volume changes in hierarch

36
OBB vs. Other Volumes - First experiment
  • Test for parallel close proximity
  • Use two concentric spheres
  • Change radius of sphere
  • One is 1 and another is 1e

37
OBB vs. Other Volumes- Second experiment
  • Test for point close proximity
  • Use two same-size spheres
  • Change distance of e

38
OBB vs. Other Volumes
  • Analysis
  • High curvature
  • No advantages for OBBs
  • Coarse tessellation
  • Have to traverse entire hierarchies
  • No advantages for OBBs
  • Quadratic convergence property is useful in
    parallel close proximity

39
Robustness and Accuracy
  • Robustness
  • Unstructured polygonal method
  • Degenerate polygons
  • No adjacency information
  • No special cases for overlap test
  • Easily implementable in hardware
  • Accuracy
  • Numerically stable
  • Error margin guards missing intersection

40
Performance
  • SGI Reality Engine
  • 90 MHZ R8000 CPU, 512MB

41
Performance - Pipe scenario
  • Smaller object is entirely embedded
  • Long thin triangles cannot efficiently
    approximated in general

42
Performance - Torus scenario
  • The spikes prevent large bounding boxes
  • The dimples provide concavities
  • The wrinkles and the twisting make it impractical
    to decompose into convex polytopes

43
Comparison with Others
  • No standard benchmark available
  • Environments
  • Based on line-stabbing, AABB and sphere tree
    algorithms
  • On SGI Indigo2 Extreme
  • About 10000 polygon models
  • About 1/71/5 a second
  • Compute all the contacts
  • Result
  • One order of magnitude improvement

44
RAPID
  • Rapid and Accurate Polygon Interference Detection
    (RAPID)
  • Implementation of OBBTree

45
Cost Evaluation - Equation
  • T Nv Cv Np Cp
  • T total cost function
  • Nv number of bounding volume pair overlap test
  • Cv cost of testing a pair of bounding volumes
    for overlap
  • Np the number primitive pairs tested for
    interference
  • Cp cost of testing a pair of primitives for
    interference

46
Cost Evaluation - Result
  • Cv is one-order magnitude slow
  • Nv is asympototically low
  • Np is asympototically low
  • It is asympototically fast for close proximity

47
Conclusion
  • OBBTree
  • A hierarchical data structure for rapid and exact
    collision detection between polygonal models
  • Efficient and fast
  • Accurate and robust

48
Reference
  • S. Gottschalk, M. C. Lin, and D. Manocha,
    "OBBTree A Hierarchical Structure for Rapid
    Interference Detection, inProceedings of the
    ACM SIGGRAPH Conference,1996, pp. 171-180.
    (Errata)
  • RAPID Homepagehttp//www.cs.unc.edu/geom/OBB/OBB
    T.html

49
QnA
Write a Comment
User Comments (0)
About PowerShow.com