ConverttoImage, SaveImages question



quick question. I’ve been saving some TIFF files (we’re saving objects identified by primary automatic, in addition to the outlines) that need to have unique greyscale IDs. Specifically, we wanted to save these images in greater than 8 bits (because 8 bits = 255 greys). However, whatever bit option we selected in SaveImages, the TIFF header was 8 bits.

Now, I’ve looked up the imwrite function documentation in google. If I’m reading this correctly, imwrite can write greyscale images at actual values.

“If A is a grayscale intensity image or a truecolor (RGB) image of class uint8, imwrite writes the actual values in the array to the file. If A is of class double, imwrite rescales the values in the array before writing, using uint8(round(255*A)). This operation converts the floating-point numbers in the range [0, 1] to 8-bit integers in the range [0, 255].”

So, my question is, is ConvertToImage converting only 256 bits? Or is SaveImages the sticking point? We’d really like to have more than 255 unique grey colors, in terms of IDing more than 255 cells per image. Is there any way we can up this? We’d like to at least have 12 bit images to work with, so we could have unique IDs for every cell in the image.


Sorry for the ridiculously long delay - we just noticed this question went unanswered, whereas usually we answer questions within a week or two! Have you resolved your problem?