Robert Schuster wrote:
-draw(new Polygon(xPoints, yPoints, nPoints));
+for (int i = 1; i < nPoints; i++)
+ draw(new Line2D.Double(xPoints[i - 1], yPoints[i - 1],
+ xPoints[i], yPoints[i]));
Hi Robert,
Line2D instances are mutable (via setLine() methods)
Hi there,
> -draw(new Polygon(xPoints, yPoints, nPoints));
> +for (int i = 1; i < nPoints; i++)
> + draw(new Line2D.Double(xPoints[i - 1], yPoints[i - 1],
> + xPoints[i], yPoints[i]));
>
> Hi Robert,
>
> Line2D instances are mutable (via setLine() methods
Hi,
> > -draw(new Polygon(xPoints, yPoints, nPoints));
> > +for (int i = 1; i < nPoints; i++)
> > + draw(new Line2D.Double(xPoints[i - 1], yPoints[i - 1],
> > + xPoints[i], yPoints[i]));
> >
> > Hi Robert,
> >
> > Line2D instances are mutable (via setLine
Hi,
thanks for the hint I will rework it that way.
Regards
Robert
David Gilbert schrieb:
> Robert Schuster wrote:
>
> -draw(new Polygon(xPoints, yPoints, nPoints));
> +for (int i = 1; i < nPoints; i++)
> + draw(new Line2D.Double(xPoints[i - 1], yPoints[i - 1],
> +