Skip to content

2D Mock: remove the non-working 'Use ROISelect' option - #42

Merged
seb5g merged 1 commit into
5.0.x_devfrom
remove/use_roi_select
Oct 4, 2026
Merged

seb5g merged 1 commit into
5.0.x_devfrom
remove/use_roi_select

Conversation

@seb5g

@seb5g seb5g commented Oct 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Removes the Use ROISelect option of daq_2Dviewer_Mock. It didn't work:

  • It cropped the image with self._ROI.
  • self._ROI was only updated by the old ROISelect(QRectF) slot, which PyMoDAQ no longer calls. Plugins now override roi_select(roi_info, ind_viewer).

Removed along with it:

  • the ROISelect slot and the _ROI attribute;
  • the cropping branch of set_Mock_data;
  • the imports that became unused.

For a working example of cropping to the ROI select, see the RoiStuff plugin of pymodaq_plugins_mockexamples (PyMoDAQ/pymodaq_plugins_mockexamples#21) and the plugin documentation in PyMoDAQ/PyMoDAQ#1238.

Test

I instantiated the plugin headless, initialized it and grabbed: two (200, 100) images, and the option is gone from the settings. The flake8 check (E9, F63, F7, F82, F401) is clean.

Related to PyMoDAQ/PyMoDAQ#1237 (code fixes in PyMoDAQ/PyMoDAQ#1240).

🤖 Generated with Claude Code

The option cropped the image with self._ROI, only set by the old ROISelect(QRectF) slot that PyMoDAQ no longer
calls (plugins now override roi_select(roi_info, ind_viewer)). See the RoiStuff plugin of
pymodaq_plugins_mockexamples for a working example of ROI select cropping.

Related to PyMoDAQ/PyMoDAQ#1237

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@seb5g
seb5g merged commit 0192ea5 into 5.0.x_dev Oct 4, 2026
1 check passed
@seb5g
seb5g deleted the remove/use_roi_select branch October 4, 2026 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant