I have a rectangular canvas and I need to verify whether a shape is totally inside that canvas or not. The shape can be lines, ellipses, arcs, rectangles and arbitrary polygons.
Does anyone know a lib with this kind of algorithm, preferably in java?
I searched and found just Slick2D, but it has a bug exactly on the method that verify if shape contains another shape.
Just to exemplifly, in the figure only shapes 2, 4, 5, and 7 are inside the canvas.
No comments:
Post a Comment