Comment 14 for bug 1404715

Revision history for this message
In , Sixtysix (sixtysix) wrote :

Created attachment 104163
quick hack

This is a patch that fixes the crashes in the three attached test cases on
my machine, it is meant to show what appears to me as the problem, the solution
probably should be decided by someone familiar with the code.

1) not returning the pointer difference as a signed int fixes the 'creduced'
   test.

2) computing the IMHO correctly rounded quotient fixes the #93749 attachment

and inserting the new edge sorted at current_y+1 fixes the live data test.

This last fix could possibly introduce the same problem for the horizontally
specular case, that is with an edge having an intersection at the same y as
its starting end-point, but at a greater x, in that case the intersection event
would be added, that is the edge 'contains' the intersection, and when the
event is processed the edges would be correctly swapped preserving the order
in the active list.

HTH