Ticket #675 (closed defect: fixed)

Opened 8 years ago

Last modified 8 years ago

Split Channels sometimes complains

Reported by: bdezonia Owned by: bdezonia
Priority: major Milestone: imagej-2.0-alpha5
Component: Legacy Compatibility Version:
Severity: serious Keywords:
Cc: Blocked By:
Blocking:

Description

Split Channels command sometimes runs and sometimes complains that it needs a multichannel image.

Open Neuron sample (multi channel) and it runs fine.

Create a new 4 channel Hypertack and it complains.

Change History

comment:1 Changed 8 years ago by bdezonia

RGBStackSplitter in IJ1 works on CompositeImages and RGB Imagepluses. I think our legacy translation is not creating a CompositeImage from the New HyperStack command. And since the image is not RGB it complains.

comment:2 Changed 8 years ago by bdezonia

Even using Edit Colors to choose CompositeMode does not affect IJ1.

comment:3 Changed 8 years ago by bdezonia

Testing in IJ1. Split channels always works for new Hyperstacks with C > 1. Regardless of how color mode is set (color, gray, compos).

comment:4 Changed 8 years ago by bdezonia

  • Summary changed from Split CHannels sometimes complains to Split Channels sometimes complains

comment:5 Changed 8 years ago by bdezonia

  • Milestone changed from biweekly-2011: Jul-18 to Jul-29 to biweekly-2011: Aug-01 to Aug-12

comment:6 Changed 8 years ago by bdezonia

Yes, the New Hyperstack command returns a 4 channel ImagePlus and not a CompositeImage. RGBStackSPlitter does not work on this kind of data.

How does IJ1 succeed here?

comment:7 Changed 8 years ago by bdezonia

It's a problem with New Hyperstack. In IJ1 it returns a CompositeImage. Called from IJ2 it does not. Investigating.

comment:8 Changed 8 years ago by bdezonia

IJ1 calls HyperStackMaker macro to create the hyperstack. Our macro support must be broken a little. Dialog UI looks fine so not sure why mode not getting set.

This bug has brought to my attention a whole list of macros shipped with IJ.jar that we need to test for compatibility.

comment:9 Changed 8 years ago by curtis

  • Milestone changed from biweekly-2011: Aug-01 to Aug-12 to imagej-2.0-alpha5

Milestone biweekly-2011: Aug-01 to Aug-12 deleted

comment:10 Changed 8 years ago by bdezonia

Since a macro is running and no IJ1 window is present imp.show() and imp.hide() terminate early without dealing with ImageWindow::close() and ImageWindow::show(). Thus created CompositeImage is not getting registered with legacy layer. Need to intercept calls to ImagePlus::show() and ImagePlus::hide() and register them with legacy layer.

comment:11 Changed 8 years ago by bdezonia

  • Status changed from new to closed
  • Resolution set to fixed

fixed in 736c97c545241fbd8189b087c2d218654d3e7bc1 and 1bb5eda8dfb913b778042b74b594be46f18d6274. Made LegacyInjector track ImagePlus show() and hide().

Note: See TracTickets for help on using tickets.