I have a tiff image of dimension 64 × 64 × 51, where 51 is my z axis or the number of image stacks. Now I want to get the brightness value for each stack corresponding to its x and y coordinates of pixel using imageJ. So if I want to get brightness value of coordinate 10,12(x,y) in image stack 5 (z) I can map it to corresponding pixels. I am unable to find any api in imageJ library which can do this.
If I work on ImagePlus object, getpixel api gives me pixel array based on x,y coordinate but I am unsure about z coordinate or the stack from which it is coming from.
ImagePlus img=new ImagePlus("some.tiff") int some=img.getPixel(10, 20);
If I get the whole image stack and get the pixel values by stack number again I am unsure of the x,y coordinate. Something like this
ImageStack is=img.getImageStack(); Object som=is.getPixels(10); // Gives me pixel values array for stack 10
I want to know if I can somehow get the pixel value based on the x,y,z coordinate which will make it easier for me to map and make sense of the data. Also I am open to exploring other libraries which can help do this for an image stack in java.