
162 4. Basic visualization
In the 2D projection plane find the intersections of all projected
edges with all the other projected edges. For each edge make
a list of the segments it is divided into . (Including the coordinates
at the ends of the segments.)
With each line segment make the following tests to see if that segment is
visible, if it is then draw it.
Repeat for every projected edge i {
Repeat for every segment j of edge i {
Projec t back from the ends of segment j to the polygon of wh ich
edge i is a boundary. This gives a depth that can be
associated with the line segment. Call these points p
1
and p
2
and let their x coordinates be x
1
and
x
2
, which ...