private Point[] constructCircle(Spline s, double ignoredAngle, Point p)
    {
        if (ignoredAngle < -Math.PI)   ignoredAngle += Math.PI * 2;
        else if (ignoredAngle > Math.PI)   ignoredAngle -= Math.PI * 2;
        double left = ignoredAngle - Math.PI / 2 - circleStep / 2;
        if (left < -Math.PI)    left += Math.PI * 2;
        double right = ignoredAngle + Math.PI / 2 + circleStep / 2;
        if (right > Math.PI)    right -= Math.PI * 2;
        boolean looped = (left < right);
        Point begin = null;
        for (double i = left; !looped || i <= right; i += circleStep)
        {
            if (i > Math.PI)
            {
                looped = true;
                i -= Math.PI * 2;
            }
            Point q = vertices.addPoint(s.x + Const.brushWidth * Math.cos(i),
                    s.y + Const.brushWidth * Math.sin(i));
            if (p != null)
                connect(p,q);
            else    begin = q;
            p = q;
        }
        Point[] result = {p, begin};
        return result;
    }