[ImageJ-devel] ROI, Overlay and UI Implementation

Curtis Rueden ctrueden at wisc.edu
Thu May 28 16:48:56 CDT 2015


Hi Cyril,

That is fantastic progress. Is your code available on GitHub yet?

> I'm on the part where I start dealing with ROI, Overlay and all.
> However, I don't know to which extent the Overlay/ROI data model goes.

I probably told you this before, but just to reiterate: you are into some
highly bleeding edge stuff, with unfinished and
still-subject-to-major-change APIs. With that caveat, here goes:

A net.imagej.overlay.Overlay is essentially a wrapper around a
net.imglib2.roi.RegionOfInterest. That latter interface is now deprecated
as the way ImgLib2 supports ROIs has been reworked as of January 2015. I
personally have not yet had time to dig into the new API that Tobias
designed, so ImageJ2 has not yet been updated.

It is furthermore confusing because ImageJ2 chose the term "overlay" to
mean something similar to what ImageJ1 means by "ROI", whereas ImageJ1 has
its own "overlay" that means something else. We are planning at least one
more iteration of the ImageJ Common data model, during which time we can
potentially select better names for these things to avoid future confusion.

ImageJ2 lets you have any number of Overlays in the same Display as one or
more Dataset (i.e., images). Conversely, in ImageJ1 there is only a single
selection (i.e., ROI) that gets replaced every time you draw -- although
you can A) add the selection to ImageJ1's ROI Manager, and/or B) add an IJ1
overlay that lets you group multiple ROIs together on the image.

Back on the IJ2 side, to make matters even more complex, IJ2's Swing user
interface "cheats" a lot by rendering its overlays using the JHotDraw
library -- via plugins of type JHotDrawAdapter, responsible for translating
between JHotDraw and ImageJ2 Overlay-based data structures. It is likely
though that your JavaFX interface will need to work differently.

In the meantime, we are happy to answer further specific questions you have
about how these classes interact.

Regards,
Curtis

On Wed, May 27, 2015 at 1:08 PM, Mongis Cyril <cyril.mongis at googlemail.com>
wrote:

> Dear all !
>
> I have been working on this new interface for ImageJ which is part of my
> PhD Thesis.
> Here is a little video showing the status of the project.
> http://cyrilmongis.net/imagejfx/imagejfx.webm
>
> I'm on the part where I start dealing with ROI, Overlay and all. However,
> I don't know to which extent the Overlay/ROI data model goes. Could you
> point me to the main classes to check when implementing a UI for
> Overlay/ROI? I also have trouble understanding the concept of Overlay. If I
> understand clearly, Overlay are just set of pixel data put on top of the
> image. But also overlays can be defined by mathematic formula or just be a
> set of pixels. At the end, they just cover the image. The Overlay tool just
> generate set of pixels that represent an Overlay over the image. But in
> ImageJ, the selection tools that we use don't really produce Overlay, they
> produce selection I guess. Are those selection ROI ? I also don't see the
> ROI in the imagej-common repository ? Are they simply in the scijava
> repository ?
>
> So in the end, could someone help by explaning or pointing ressources
> explaning how the classes involved in ROIs and Overlays interact between
> each other ?
>
> I have already check the OverlayService, but I couldn't find any
> RoiService :-(
>
> Cheers,
>
> Cyril
>
> _______________________________________________
> ImageJ-devel mailing list
> ImageJ-devel at imagej.net
> http://imagej.net/mailman/listinfo/imagej-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://imagej.net/pipermail/imagej-devel/attachments/20150528/ab37ff21/attachment.html>


More information about the ImageJ-devel mailing list