java2d: writing graphics vigilant line
is there proceed graphics object's 'setclip()' slight trim controlling line-ish shape? right i'm perplexing polygon figure nonetheless i'm carrying problems simulating "width" line. i fundamentally pull line, i strech end, i redraw nonetheless subtract line extent y-coordinate:
polygon poly = new polygon();
for(int i = 0; i < points.length; i++)
poly.addpoint(points.[i].x, points.[i].y);
// retrace line supplement 'width'
for(int i = points.length - 1; i >=0; i--)
poly.addpoint(points[i].x, points[i].y - lineheight);
it roughly works nonetheless extent line varies formed on the slope.
i can't brushstroke drawline() methods since line change tone once passes erratic anxiety line. there doing figure i overlooked, an easy i create, let me some-more easily?
Comments
Post a Comment