Skip to main content
1 of 2

How to build Masks (0-1 binary image) out of ROIs in Envi Classic?

I have the following 701x551 image in Envi with the shown raster ROIs (By pressing pixelbutton of ROI Tooldialogue window, I've converted the ROIs into raster format but I have access to ROI vectors eg. polygons if necessary) as training data.
enter image description here
I want to extract a binary image (a mask) with 701x551 pixels in Envi format in which the pixels inside the ROI are 1 and outside the ROI are 0, so I can use the ROIs as a matrix of 0-1 values and multiply it with my 701x551 data matrix in MATLAB to extract the the training vector for libsvm tool. Are there any way to do such thing? (I'm using the classic GUI of Envi 5.3)