Re: AddSlice to Composite Image causes exception
Posted by
Rasband, Wayne (NIH/NIMH) [E] on
Feb 13, 2011; 12:57am
URL: http://imagej.273.s1.nabble.com/AddSlice-to-Composite-Image-causes-exception-tp3685705p3685706.html
On Feb 12, 2011, at 6:08 AM,
[hidden email] wrote:
> There seems to be a problem when adding an extra slice to a composite image. Problem seems to be easily reproduced with the following macro:
>
> newImage("Untitled", "8-bit White", 400, 400, 3);
> run("Make Composite", "display=Composite");
> run("Add Slice");
>
> The following exception is thrown:
>
> java.lang.ArrayIndexOutOfBoundsException: 3
> at ij.CompositeImage.updateImage(CompositeImage.java:290)
> at ij.CompositeImage.updateAndDraw(CompositeImage.java:180)
> at ij.ImagePlus.updateAndRepaintWindow(ImagePlus.java:300)
> at ij.ImagePlus.setSlice(ImagePlus.java:1280)
> at ij.plugin.StackEditor.addSlice(StackEditor.java:50)
> at ij.plugin.StackEditor.run(StackEditor.java:24)
> at ij.IJ.runPlugIn(IJ.java:156)
> at ij.Executer.runCommand(Executer.java:124)
> at ij.Executer.run(Executer.java:61)
> at ij.IJ.run(IJ.java:249)
> at ij.IJ.run(IJ.java:227)
> at ij.macro.Functions.doRun(Functions.java:563)
> at ij.macro.Functions.doFunction(Functions.java:79)
> at ij.macro.Interpreter.doStatement(Interpreter.java:203)
> at ij.macro.Interpreter.doStatements(Interpreter.java:191)
> at ij.macro.Interpreter.run(Interpreter.java:102)
> at ij.macro.Interpreter.run(Interpreter.java:72)
> at ij.macro.MacroRunner.run(MacroRunner.java:124)
> at java.lang.Thread.run(Thread.java:680)
>
> The problem is reproducible and appears on both Mac and PC platforms.
> Currently testing with imageJ 1.4.5a and Java 6.0
This bug is fixed in the 1.45b daily build.
-wayne