-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable ImageJ2 syncing by default #82
Conversation
Otherwise, Swing renders the tooltip all on one long line.
This option is off by default, to avoid disrupting IJ1-based workflows. When the option is enabled, newly created ImagePlus objects will be synced to ImageJ2 ImageDisplays. Ideally, this would be a lazy/cheap operation, but at the moment it is too expensive. Fixes Fiji bug 899: http://fiji.sc/bugzilla/show_bug.cgi?id=899 Or at least: it avoids the problem for users by default, which is good enough for now.
When ImagePlus#close is called, it calls LegacyHooks#unregisterImage, which in turn calls LegacyImageMap#unregisterLegacyImage, which calls LegacyImageMap#removeMapping, which calls LegacyUtils#deleteImagePlus, which was calling close again, resulting in a stack overflow. It may cause other problems not to call close anymore from LegacyUtils#deleteImagePlus, but at least they won't be as bad as a stack overflow.
|
@dscho, @hinerm: I think it is paramount that we disable the IJ1 Unfortunately, use cases like #81 (already buggy) become even less tenable while the syncing is disabled. But the IJ2 API needs another design iteration before it will be usable anyway. Anyway, let me know if you see any problems with the patch set; I only tested it lightly. Commit 2729b90 in particular worries me a little. |
|
I agree that this is a good change. We need to focus more on our immediate projects and refrain from trying to support everybody else's projects better. That means synchronization in particular because we do not need it. It would have been nice, but there are bigger fish we need to fry, like, right now. Also, I am not too worried about 2729b90: it is relevant only in the context of a full synchronization between IJ1 and IJ2 data structures, which we agreed recently is no longer what we aim for. |
Disable ImageJ2 syncing by default
This branch adds a toggle for this syncing, which is now disabled by default, to avoid performance problems for regular users of ImageJ 1.x functionality, while still allowing interested people to turn on the syncing to try out new ImageJ2 features as they mature.
The syncing of ImageJ1 data structures to ImageJ2 causes a substantial performance penalty, due to limitations and bugs in the ImageJ2 data structure classes. In particular, as soon as an IJ2
ImageDisplayis created, it attempts to render aScreenImageat full resolution even though the display is never shown onscreen. While we certainly can (and need to) fix that issue, in the meantime, let's disable ImageJ2 syncing.This branch fixes Fiji bug 899.