Converting ROIs
Posted by
Andy Weller on
Aug 02, 2006; 1:16pm
URL: http://imagej.273.s1.nabble.com/Converting-ROIs-tp3701905.html
Dear all,
Is there a macro way to convert between different ROI types?
I am using the run("Create Selection") command that creates a composite
ROI but I need a "Polygonal or point selection" required. My previous
get-out clause was to do the following:
run("Enlarge...", "enlarge=0");
run("Fit Spline");
which seemed to work... Sometimes... I guess there's a 'clean' way to do
it as I've seen the various saving methods in class RoiWriter
(
http://rsb.info.nih.gov/ij/developer/source/ij/plugin/filter/RoiWriter.java.html).
case Roi.POLYGON: name="Polygon.roi"; break;
case Roi.FREEROI: name="Freehand.roi"; break;
case Roi.TRACED_ROI: name="TracedRoi.roi"; break;
case Roi.OVAL: name="Oval.roi"; break;
etc
Thanks, Andy