/** Returns this OvalRoi as a Polygon. */ public Polygon getPolygon() { ImageProcessor mask = getMask(); Wand wand = new Wand(mask); wand.autoOutline(width/2,height/2, 255, 255); for (int i=0; i<wand.npoints; i++) { wand.xpoints[i] += x; wand.ypoints[i] += y; } return new Polygon(wand.xpoints, wand.ypoints, wand.npoints); }
/** Returns this OvalRoi as a Polygon. */ public Polygon getPolygon() { ImageProcessor mask = getMask(); Wand wand = new Wand(mask); wand.autoOutline(width/2,height/2, 255, 255); for (int i=0; i<wand.npoints; i++) { wand.xpoints[i] += x; wand.ypoints[i] += y; } return new Polygon(wand.xpoints, wand.ypoints, wand.npoints); }
if (dotMask==null || lineWidth!=dotMask.getWidth()) { OvalRoi oval = new OvalRoi(0, 0, lineWidth, lineWidth); dotMask = oval.getMask();
if (dotMask==null || lineWidth!=dotMask.getWidth()) { OvalRoi oval = new OvalRoi(0, 0, lineWidth, lineWidth); dotMask = oval.getMask();