NOTICE! This is a static HTML version of a legacy ImageJ Trac ticket.

The ImageJ project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Ticket #1061 (closed defect: fixed)

Opened 2012-03-07T15:48:30-06:00

Last modified 2012-03-08T15:40:57-06:00

Add axis causes exception in probe

Reported by: bdezonia Owned by: bdezonia
Priority: major Milestone: imagej2-b1-initial
Component: Plugins Version:
Severity: serious Keywords:
Cc: Blocked By:
Blocking:

Description

Create a new pure IJ2 float image. Add axis Z. Now move probe over image. Exception (below) thrown repeatedly.

Debugging shows PixelRecorder has correct multidim coords. But it's like the PlanarImg internal reference never updated after the new ImgPlus assigned by add axis plugin.

[ERROR] Exception during event handling:

[Event] imagej.ext.display.event.input.MsMovedEvent
context = imagej.ImageJ@72b9dc79
consumed = false
display = imagej.ui.swing.sdi.display.SwingSdiImageDisplay@6f731eba
modifiers =
x = 511
y = 413
[Subscriber] imagej.ext.tool.DefaultToolService@5da36300
[Method] protected void imagej.ext.tool.DefaultToolService.onEvent(imagej.ext.display.event.input.MsMovedEvent)

java.lang.IndexOutOfBoundsException: Index: 2, Size: 2

at java.util.ArrayList.RangeCheck(ArrayList.java:547)
at java.util.ArrayList.get(ArrayList.java:322)
at net.imglib2.img.planar.PlanarImg.update(PlanarImg.java:134)
at net.imglib2.img.planar.PlanarImg.update(PlanarImg.java:1)
at net.imglib2.type.numeric.real.FloatType.updateContainer(FloatType.java:89)
at net.imglib2.img.planar.PlanarRandomAccess.setPosition(PlanarRandomAccess.java:166)
at net.imglib2.img.planar.PlanarRandomAccess.setPosition(PlanarRandomAccess.java:175)
at imagej.core.tools.PixelRecorder.setPosition(PixelRecorder.java:215)
at imagej.core.tools.PixelRecorder.record(PixelRecorder.java:165)
at imagej.core.tools.PixelProbe.onMouseMove(PixelProbe.java:70)
at imagej.ext.tool.DefaultToolService.onEvent(DefaultToolService.java:244)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at imagej.event.DefaultEventService$ProxySubscriber.onEvent(DefaultEventService.java:224)
at imagej.event.DefaultEventService$ProxySubscriber.onEvent(DefaultEventService.java:1)
at org.bushe.swing.event.ThreadSafeEventService.publish(ThreadSafeEventService.java:971)
at org.bushe.swing.event.SwingEventService.publish(SwingEventService.java:78)
at org.bushe.swing.event.ThreadSafeEventService.publish(ThreadSafeEventService.java:904)
at imagej.event.DefaultEventService.publish(DefaultEventService.java:90)
at imagej.ui.common.awt.AWTMouseEventDispatcher.mouseMoved(AWTMouseEventDispatcher.java:178)
at java.awt.AWTEventMulticaster.mouseMoved(AWTEventMulticaster.java:313)
at java.awt.AWTEventMulticaster.mouseMoved(AWTEventMulticaster.java:312)
at java.awt.Component.processMouseMotionEvent(Component.java:6418)
at javax.swing.JComponent.processMouseMotionEvent(JComponent.java:3285)
at java.awt.Component.processEvent(Component.java:6142)
at java.awt.Container.processEvent(Container.java:2085)
at java.awt.Component.dispatchEventImpl(Component.java:4735)
at java.awt.Container.dispatchEventImpl(Container.java:2143)
at java.awt.Component.dispatchEvent(Component.java:4565)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4295)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)
at java.awt.Container.dispatchEventImpl(Container.java:2129)
at java.awt.Window.dispatchEventImpl(Window.java:2478)
at java.awt.Component.dispatchEvent(Component.java:4565)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:679)
at java.awt.EventQueue.access$000(EventQueue.java:85)
at java.awt.EventQueue$1.run(EventQueue.java:638)
at java.awt.EventQueue$1.run(EventQueue.java:636)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
at java.awt.EventQueue$2.run(EventQueue.java:652)
at java.awt.EventQueue$2.run(EventQueue.java:650)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:649)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Change History

comment:1 Changed 2012-03-08T15:40:57-06:00 by bdezonia

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

Fixed by 5a4479246e89ae5e3b4450184a864f3bc72ca8cb