Fix an error in the clip tables
There was an error in the clip tables for clipping lines. It was referring to edge 1 for one of the case, but of course a line has only 1 edge at index 0. Fix the error in the clipping table and also add a check for if we get an index to an invalid line.
Showing with 31 additions and 26 deletions