Graphics Reference
In-Depth Information
200
175
150
125
100
75
50
25
400
800
1,200
1,600
Distance
FIGURE 7.16
Kinematic response to collisions with ground using 0.8 as the damping.
is not physically based, but it produces reasonable visuals, especially for particles and spherically
shaped objects. Incorporating kinematic response to collisions with the ground produces Figure 7.16 .
ðt i Þ
ðt i Þ
v
ðt 1 Þ¼
v
ðt i Þð
v
N
Þ
N
v
N
Þ
N
(7.53)
ðt i Þ
¼
v
ðt i Þð
1
þ kÞð
v
N
Þ
N
The penalty method
When objects penetrate due to temporal sampling, a simple method of constructing a reaction to the
implied collision is the penalty method . As the name suggests, a point is penalized for penetrating
another object. In this case, a spring, with a zero rest length, is momentarily attached from the offending
point to the surface it penetrated in such a way that it imparts a restoring force on the offending point.
For now, it is assumed that the surface it penetrates is immovable and thus does not have to be con-
sidered as far as collision response is concerned. The closest point on the penetrated surface to the pen-
etrating point is used as the point of attachment (see Figure 7.17 ) . The spring, therefore, imparts a force
on the point in the direction of the penetrated surface normal and with a magnitude according to
Hooke's law ( F ¼kd ). A mass assigned to the point is used to compute a resultant acceleration
( a ¼ F / m ), which contributes an upward velocity to the point. When this upward velocity is combined
with the point's original motion, the point's downward motion will be stopped and reversed by the
spring, while any component of its motion tangent to the surface will be unaffected. While easy to
implement, this approach is not ideal. An arbitrary mass ( m ) must be assigned to the point, and an arbi-
trary constant ( k ) must be determined for the spring. It is difficult to control because if the spring
point p at t i 1
d
Penalty force
point p at t i
FIGURE 7.17
Penalty spring.
 
Search WWH ::




Custom Search