Allow creation of small image from ROI
Allow creation of small image from ROI

Code example (on the tissue image):

var mask=img.grey().mask();

var roiManager=img.getROIManager();
roiManager.putMask(mask);

var rois=roiManager.getROI();
var image=rois[400].extract(img);
setRight(image);

// Just to test performances ...
var start=new Date();
for (var i=0; i<rois.length; i++) {
    var image=rois[i].extract(img);
}
console.log(new Date()-start);

image-js/ij,image-js/core,image-js/core,image-js/image-js,image-js/ij,image-js/ij,image-js/image-js