ImageJ/Fiji has several different types of Rois: Rectangle, Oval, Polygon, Freehand, Traced, Straight Line, Polyline, Freeline, Angle, Composite, Point, Text, and Image. These types can refer to the shape of the Roi, or the method by which the Roi was created. Traced Rois, for example, are usually the result of using the Wand tool and they can be a variety of shapes.
getRoisAsArray method returns a
Roi. However, when you inspect this array or try to print its values it will call the
toString method of
Roi. In the case of Traced Rois, this will display the type of the Roi, the coordinates of the upper left hand corner of the bounding box, and the width and height of the bounding box.
So you are correct that what is being displayed when you print this element of the array ([Traced, x=‘int’, y=‘int’, width=‘int’, 'height=‘int’]) is defining a rectangle, but that rectangle is only the bounding box of the Traced Roi and the Traced Roi within this bounding box can take on a variety of shapes (such as many rectangles ). If you’d like the vertices of this Traced Roi you could call
getYCoordinates on it.
Hopefully that helps, but if not please feel free to ask additional questions.