I have polygon and a line.
g.drawLine(this.getLine().getP1().getX(), this.getLine().getP1().getY(),
this.getLine().getP2().getX(), this.getLine().getP2().getY());
g.drawPolygon(this.polygon);
and I have to find the cross-points between the polygon and the line(if any), and what part of the line is in the polygon. Any ideas how to do that .