Skip to content

Image contrast widget: symmetric range adjustment, image creation from contrast settings, and exposure preview #370

Open

Description

@ThomasMalletCodra

Is your feature request related to a problem? Please describe.

The image contrast adjustment widget currently offers no way to reuse its settings beyond display, and adjusting a level range around a point of interest is tedious:

  • Dragging one bound of the histogram range moves that bound only, so keeping a chosen center value while widening or narrowing the range requires repeatedly readjusting both bounds.
  • The range selected in the widget only affects the displayed LUT. There is no way to turn the visually tuned contrast into an actual processed image, so users must re-enter the same min/max values manually in an exposure processing dialog.

In addition, exposure processing dialogs (gamma, log, sigmoid, intensity rescaling, histogram equalization, brightness/contrast, ...) currently give no visual feedback: parameters must be validated blindly, then undone and retried if the result is not the expected one.

Describe the solution you'd like

This request covers two largely independent improvements:

1. Image contrast widget (image view)

  • Symmetric range adjustment with Ctrl: holding Ctrl while dragging a bound of the contrast range expands/shrinks the range symmetrically around its center, leaving the center value unchanged. This mirrors the existing
    behavior of circle annotations on images, where Ctrl-dragging changes the diameter without moving the center.
  • Create an image from the current contrast settings: add a button to the contrast widget that generates a new image object from the currently
    displayed range, by running the corresponding exposure processing pre-configured with the widget's min/max values. The result is a regular
    DataLab image object (with processing parameters stored in metadata, so it can be recomputed and edited like any other processed object).

2. Exposure processing dialogs

  • Live preview: add a preview option to exposure processing parameter dialogs, so the effect of the parameters can be evaluated before validating the operation.

Additional context

  • Affected components: PlotPy (contrast adjustment panel and histogram range item interaction), guidata (parameter widget gesture notifications), Sigima (exposure computation used by the "create image" action), DataLab (widget integration, processing dialog preview, tests and documentation).

  • The two parts can be delivered independently : the exposure preview does not depend on the contrast widget changes.

See #368

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions