Main Content

imroi Class

(Not recommended) Region-of-interest (ROI) abstract base class

The imroi abstract class and its inherited classes are not recommended. Use new ROI objects instead. For more information, see Version History.

Description

The imroi class is an abstract base class that specifies the Image Processing Toolbox™ interface for working with regions of interest (ROIs). You can use classes that inherit from the imroi interface to create interactive ROIs over an image.

The imroi class is a handle class.

Class Attributes

Abstract
true

For information on class attributes, see Class Attributes.

Creation

The imroi class is abstract, and creating an instance of the imroi class is not allowed. To learn how to create an ROI object from a concrete subclass of imroi, see imellipse, imfreehand, imline, impoint, impoly, or imrect.

Properties

expand all

ROI can be deleted, specified as true or false.

Attributes:

GetAccess
public
SetAccess
public

Data Types: logical

Methods

expand all

Version History

Introduced in R2008a

collapse all

R2018b: imroi is not recommended

Starting in R2018b, a new set of ROI objects replaces the existing set of ROI objects. The new objects provide more functional capabilities, such as face color transparency. The new classes also support events that you can use to respond to changes in your ROI such as moving or being clicked. Although there are no plans to remove the old ROI objects at this time, switch to the new ROIs to take advantage of the additional capabilities and flexibility. For more information on creating ROIs using the new ROI functions, see Create ROI Shapes.

For more information on updating code using instances of imroi objects to the new ROI objects, see ROI Migration.