i dont know how far you have gotten with this but i have been thinking about it since yesterday.
after having read the link posted by ancient dragon i think that i might have some way but it is crude and i cannot guarentee that i would actually succeed. also i would need a lot of time. but it is a really interesting project and i would like to work on it too. perhaps we can work on it seperately and continuously compare notes.
to begin with i want to ask you a few questions.
is the plane a flat surface? if it is a curved surface then i would be lost since my mathematics only extend to geometry on a two dimensional plane.
then there are the lines themselves
are the lines known at compile time or are they supplied at run time.
also are they straight lines or curves(quadratic equations) . (i.e. y = mx + c or y = ax2 + bx + c ).
also if these equations is of a order higher than quadratic then i would have some difficulty working with them. even if i could work with them i would have difficulty translating a line of this type into an algebraic equation of this type.
also does the lines have an interval. i mean do these lines have an end and a beginning?