Re: How to color differently each slice of a stack or each ImageProcessor

Posted by ctrueden on
URL: http://imagej.273.s1.nabble.com/How-to-color-differently-each-slice-of-a-stack-or-each-ImageProcessor-tp5000664p5000679.html

Hi Ferdinando,

> I'm new to ImageJ and I'm trying to write a plugin that colors each
> slice of an ImageStack differently one from another.

You can use RGB Color images to color each slice however you like.

> In particular, I need to select an area of a slice and change the
> color of it, adding transparency.

ImageJ does not support alpha channels directly. To replicate the
appearance of an alpha channel you would have to do the math yourself.
Michael Schmid's Alpha Channel plugin [1] may be useful to you for that.

If what you want is to read or write PNG data with an alpha channel, but
don't care so much about visualizing the transparency in ImageJ
specifically, then see this thread [2].

Regards,
Curtis

[1]
http://imagejdocu.tudor.lu/doku.php?id=plugin:utilities:alpha_channel:start
[2] http://permalink.gmane.org/gmane.comp.java.imagej/20228


On Sun, Nov 4, 2012 at 10:36 AM, thehobbit <[hidden email]> wrote:

> Hello everyone,
>
> I'm new to ImageJ and I'm trying to write a plugin that colors each slice
> of
> an ImageStack differently one from another.
> I'm working with DICOM images.
> In particular, I need to select an area of a slice and change the color of
> it, adding transparency.
> I tried different solutions, but I was able only to color all the slices of
> the stack in the same way.
> I tried also to work with ImageProcessors, and they works fine for my
> problem; but here comes another one:
> as I said in the subject, I need a color transparency, in such a way that
> the selected area is colored and at the same time I can see what there is
> behind it. But ImageProcessors seems to work at a very low level, and I'm
> able only to change the colours of the pixels(without transparency), losing
> previous data.
>
> Can you help me with this please?
> Thanks in advance.
>
>
>
>
>
> --
> View this message in context:
> http://imagej.1557.n6.nabble.com/How-to-color-differently-each-slice-of-a-stack-or-each-ImageProcessor-tp5000664.html
> Sent from the ImageJ mailing list archive at Nabble.com.
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html