Ticket #1282 (closed defect: fixed)

Opened 7 years ago

Last modified 7 years ago

Edit >> Cut may use wrong fill value

Reported by: bdezonia Owned by: bdezonia
Priority: major Milestone: imagej2-b4-plugins
Component: Legacy Compatibility Version:
Severity: serious Keywords:
Cc: Blocked By:
Blocking: #1331, #1341

Description

When you run Edit >> CUt it is supposed to fill with the background value(s). But the plugin fills in with the last background value IJ1 knows about. This may not be exactly the same as the current Options >> Channels bg values. Determine why they are not in sync and fix.

Change History

comment:1 Changed 7 years ago by bdezonia

  • Blocking 1331 added

comment:2 Changed 7 years ago by bdezonia

  • Blocking 1341 added

comment:3 Changed 7 years ago by bdezonia

The IJ1 colors are only ever updated when the PickerTool has been run. If a user enters values into the OptionsChannels values no change is made to the IJ1 colors.

One possible solution is to map the new channel values into a color for the currently active DatasetView. If no view active then do not update the IJ1 colors otherwise do. The DatasetView would know how many channels to pull out depending upon the number of converters it's projector and also whether to composite the channels. This seems like a reasonable approach.

One obstacle to this approach is that options plugins live in ij-core while key classes live in ij-data. We may need to move the options classes into ij-data. And that might have other ramifications.

When there is no active dataset view the IJ1 colors can become stale. Although upon running a legacy plugin maybe we'd set the options channels to their current values which would then use the active DatasetView to map colors before the IJ1 plugin runs. Maybe always doing this is the real solution.

comment:4 Changed 7 years ago by bdezonia

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

Fixed with commit b48302ce10ab1c5f9ba55b05271220b60917f444.

Every time a legacy plugin is run the IJ1 colors are first set by mapping the current channel values to a color using the current DatasetView's lut converters and color tables.

Note: See TracTickets for help on using tickets.