
180 5. Realistic visualization
i f p
1z
− p
0z
< ǫ {
return no intersection line does not cross plane
}
Let µ =
z
0
− p
0z
p
1z
− p
0z
and α = p
0x
+ µ(p
1x
− p
0x
)
Then i f α ≤ X
min
or α ≥ X
max
{
return no intersection cro s s es plane outside box
}
Let β = p
0y
+ µ(p
1y
− p
0y
)
i f β ≤ Y
min
or β ≥ Y
max
{
return no intersection cro s s es plane outside box
}
return intersection
5. The 12 edges are ch ecked against the polygon using the lin e triangle inter-
section algorithm described in section 2.11.1.
Even though the above s tep s have been describ ed for triangular polygon s
there is no reason why the procedu r e could not be applied to any convex planar
polygon.
5.3.5 A simple o