Commit b9421a8d authored by Benedikt Zoennchen's avatar Benedikt Zoennchen

remove triangles from the triangulation if they intersect any obstacle.

parent acd19fc5
......@@ -124,16 +124,16 @@ public class VRectangle extends Rectangle2D.Double implements VShape {
return new VPolygon(this);
}
@Override
public boolean intersect(final VShape shape) {
if(shape instanceof VRectangle){
return intersects(((VRectangle)shape));
}
else if(shape instanceof VPolygon) {
return shape.intersect(this);
}
else {
throw new UnsupportedOperationException("not yet implemented");
}
}
@Override
public boolean intersect(final VShape shape) {
if(shape instanceof VRectangle){
return intersects(((VRectangle)shape));
}
else if(shape instanceof VPolygon) {
return shape.intersect(this);
}
else {
throw new UnsupportedOperationException("not yet implemented");
}
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment