I have java general path with random points. I want to crop one side of it and get straight line.
How to make it?
I have java general path with random points. I want to crop one side of it and get straight line.
How to make it?
Area
based on the 1st GeneralPath
based on this constructor. I'll call it mainArea
. Rectangle2D
based on the line, covering the area to the left of it as well. I'll call it lineArea
. Area.subtract(Area)
using mainArea.subtract(lineArea);
An example can be seen in this answer.