MATLAB: How to store the output of several of structures produced from “bwconncomp”

pixelidxlist field

I have an image and divide this image into blocks, I apply connected component function called "bwconncomp" to each block, I need to store the PixelIdxList field of the structure produced from function "bwconncomp" for each block?

Best Answer

variablename = {structurename.PixelIdxList};
You need the cell array because the entries can be different sizes.