unexpected results with "Convert Stack to RGB"

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

unexpected results with "Convert Stack to RGB"

seb-7
Hello ImageJers,

I got something pretty weird using "Convert Stack To RGB" with last
(1.37k) version of ij:
Instead of the usual RGB merged slices, I got 2 windows: one of "RGB"
type containig one (gray) image coming from one slice of the previous
stack and an "empty" blank stack (with a slider but nothing displayed).
Moreover when I select a slice in the last one, it is displayed in the
result "RGB" stack.
I checked this with the same version of ij, both on linux and OSX
(Tiger) (java 1.5.0x).

I fear this is not crystal clear...

Here is a macro showing what I did:

newImage("test", "8-bit Black", 512, 512, 3);
setColor(200);
for(i=1;i<=3;i++)
{
        setSlice(i);
        fillRect(i*50,i*50,100,100);
}
run("Convert Stack to RGB");


Can you see what I mean?

I'm trying to look at the source now.

Thanks
seb
Reply | Threaded
Open this post in threaded view
|

Re: unexpected results with "Convert Stack to RGB"

Gabriel Landini
On Wednesday 19 July 2006 16:17, seb wrote:
> I got something pretty weird using "Convert Stack To RGB" with last
> (1.37k) version of ij:
> Instead of the usual RGB merged slices, I got 2 windows: one of "RGB"
> type containig one (gray) image coming from one slice of the previous
> stack and an "empty" blank stack (with a slider but nothing displayed).
> Moreover when I select a slice in the last one, it is displayed in the
> result "RGB" stack.
> I checked this with the same version of ij, both on linux and OSX
> (Tiger) (java 1.5.0x).

Not sure what the problem is, but you can avoid it.
Try this:

newImage("test", "RGB Black", 512, 512,1);
run("RGB Stack");

setColor(200);
for(i=1;i<=3;i++)
{
        setSlice(i);
        fillRect(i*50,i*50,100,100);
}

run("RGB Color");

Cheers,

G.
Reply | Threaded
Open this post in threaded view
|

Re: unexpected results with "Convert Stack to RGB"

Wayne Rasband
In reply to this post by seb-7
This is a bug that is fixed in ImageJ 1.27l, due next week.

-wayne

On Jul 19, 2006, at 11:17 AM, seb wrote:

> Hello ImageJers,
>
> I got something pretty weird using "Convert Stack To RGB" with last
> (1.37k) version of ij:
> Instead of the usual RGB merged slices, I got 2 windows: one of "RGB"
> type containig one (gray) image coming from one slice of the previous
> stack and an "empty" blank stack (with a slider but nothing
> displayed). Moreover when I select a slice in the last one, it is
> displayed in the result "RGB" stack.
> I checked this with the same version of ij, both on linux and OSX
> (Tiger) (java 1.5.0x).
>
> I fear this is not crystal clear...
>
> Here is a macro showing what I did:
>
> newImage("test", "8-bit Black", 512, 512, 3);
> setColor(200);
> for(i=1;i<=3;i++)
> {
> setSlice(i);
> fillRect(i*50,i*50,100,100);
> }
> run("Convert Stack to RGB");
>
>
> Can you see what I mean?
>
> I'm trying to look at the source now.
>
> Thanks
> seb
>