http://imagej.273.s1.nabble.com/Measuring-RGB-Color-data-within-a-non-rectangular-ROI-tp5014469p5014478.html
I've encountered a similar scenario like you. What worked for me was to use
It will measure the Min,Max of the RGB channels.
> The title says it all. I'm attempting to write a small macro that will
> segment an image, based on a SIOX file,turn it into a mask, do some
> processing, and then add all the outlines in the mask as ROIs to the ROI
> manager. This part, I have been able to do successfully so far.
>
> The issue is that I'm trying to then iterate over each ROI and return a
> results table, with a row for each ROI, and columns for size, Red value,
> Blue value, and Green value. I know you can get size from the "measure"
> command, but I haven't been able to successfully get RGB values (except in
> histogram form).
>
> Also, if the ROI is not rectangular, does it extrapolate the extreme points
> and measure as if it were a rectangular ROI? I read somewhere that it does
> that, but that would make this color date include a lot of the background,
> which I am hoping to avoid.
>
> Best,
> Caleb
>
> --
> ImageJ mailing list:
http://imagej.nih.gov/ij/list.html>