public Point getPoint(int x, int y){
        for(Point actPoint:bendPoints){
            if (x >= actPoint.getX() - 5 && x<= actPoint.getX() + 5
                    && y >= actPoint.getY() - 5 && y <= actPoint.getY() + 5) {
                return actPoint;
            }            
        }             
        return null;
    }