Graphics Reference
In-Depth Information
P
A
B
A
B
L
(a)
(b)
Figure 5.13
(a) Two convex objects,
A
and
B
, separated by a hyperplane
P
(one of many
possible hyperplanes). Stated equivalently,
A
and
B
are nonoverlapping in their projection
onto the separating axis
L
(which is perpendicular to
P
). (b) The same convex objects are in an
intersecting situation and therefore not separable by any hyperplane.
P
C
A
C
B
r
A
r
B
L
d
Figure 5.14
Two objects are separated if the sum of the radius (halfwidth) of their projections
is less than the distance between their center projections.
oriented rectangle (or, equivalently, a sphere and an OBB, as seen from the side).
First, for each object, a supporting point along
L
is obtained; that is, a point most
distant from the object center along either direction of
L
(in that the projections are
symmetrical, the direction does not matter; there will be a point equally distant in
both directions). The two object radii,
r
A
and
r
B
, are then obtained by computing the
distance between the projections onto
L
of the object centers and their respective
most distant points. The distance
d
between the center projections is also computed.
Given these computed quantities, the objects are now separated if
r
A
+
<
r
B
d
.