8.1 The Method of Separating Axes 439
The algebraic condition that describes the separated intervals in Figure 8.17 (a)
is |γ
1
− γ
0
| >r
0
+ r
1
. In words, this says that the distance between the centers of the
projected intervals is larger than the sum of the radii of the intervals. The intervals in
the bottom image of the figure overlap, so |γ
1
− γ
0
| <r
0
+ r
1
. If the intervals are just
touching, |γ
1
− γ
0
|=r
0
+ r
1
. This last case is important when dealing with moving
OBBs.
Define r =|γ
1
−γ
0
|. A closer look at the algebraic condition for separation of the
projected intervals shows that
r =|γ
1
− γ
0
|=|D
.
(C
1
− Q) − D
.
(C
0
− Q)|=|D
.
(C
1
− C
0
)|
This means we need to specify only the direction D and not worry about providing a
point Q on the line. Also,
r
0
=
2
i=0
a
i
|D
.
A
i
|, r