Skip to content

Additional improvements 3d renderer from contributor#1106

Closed
keejkrej wants to merge 8 commits into
SchmollerLab:improvements_3d_rendererfrom
keejkrej:improvements_3d_renderer
Closed

Additional improvements 3d renderer from contributor#1106
keejkrej wants to merge 8 commits into
SchmollerLab:improvements_3d_rendererfrom
keejkrej:improvements_3d_renderer

Conversation

@keejkrej

Copy link
Copy Markdown
Contributor

No description provided.

keejkrej and others added 5 commits May 25, 2026 09:30
Integrate overlays as overlay:N entries in _volume_nodes, unify rendering
helpers, and add Auto/Full LUT controls plus a working Home toolbar shortcut.
Move plain-colour cmap handling to colors.vispy_cmap_from_spec and refresh tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
Restore the module-level pytest skip for test_renderer3d (5fdb923) and use
the controls step size for primary volume relative_step_size, matching the
pre-e8aceb63 renderer UI work.

Co-authored-by: Cursor <cursoragent@cursor.com>
Add Clim myHistogramLUTitem, right-side opacity colorbar, in-renderer overlay
controls, bidirectional sync with the main GUI, and roadmap docs under .features/.

Co-authored-by: Cursor <cursoragent@cursor.com>
Add label volume masking, Cell ID selector with Show all, Shift+click pick,
and bidirectional sync with the main GUI props and highlight toolbar.

Co-authored-by: Cursor <cursoragent@cursor.com>
Add a user-facing dz/dx ratio with optional Z resampling so frame sync no longer overwrites manual anisotropy settings.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ElpadoCan ElpadoCan changed the title Improvements 3d renderer Additional improvements 3d renderer from contributor May 25, 2026
@ElpadoCan

ElpadoCan commented May 25, 2026

Copy link
Copy Markdown
Collaborator

Hi @keejkrej,

Regarding this, I will only take inspiration to finish my other PR #1102 because there are errors that might take longer to fix than just taking what works. I'm still testing what works best for multiple channels, anyway. I will keep you updated. Thanks for the contributions!

@keejkrej

Copy link
Copy Markdown
Contributor Author

@ElpadoCan no problem, i haven't tested this ai slop myself yet :P

@keejkrej keejkrej marked this pull request as draft May 25, 2026 16:55
keejkrej and others added 3 commits May 25, 2026 22:22
Initialize the renderer UI before preprocessing on the first update_volume call so _controls exists, and guard _preprocess_volume when controls are not yet available. Also add a direct GUI entry point and lazy brush/eraser strokes for click-move-click editing.
…t tools.

Remove delete-object shortcut customization and bidirectional 2D/3D sync in favor of one-way pushes from the main GUI. Add LUT-aware label rendering, segmentation-only mode, BF/segm blend, and KEYBINDS.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@ElpadoCan

ElpadoCan commented May 26, 2026

Copy link
Copy Markdown
Collaborator

Hi @keejkrej,

This is going in a very promising direction! The overlaid segmentation labels work very well. However, if I open the renderer with multiple fluorescence channels, I get this error

File "C:\Users\Frank\Cell_ACDC_2\cellacdc\renderer3d.py", line 1255, in _rebuild_overlay_controls
    row_layout.addWidget(lut_item)
    ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
TypeError: addWidget(self, a0: Optional[QWidget], stretch: int = 0, alignment: Qt.AlignmentFlag = Qt.Alignment()): argument 1 has unexpected type 'baseHistogramLUTitem'

This is because the row_layout should be a pg.GraphicsLayoutWidget().

Anyway, do you think this could be fixed? Because then I could take it from there and the bulk of the work would be done. Thanks!

@keejkrej

Copy link
Copy Markdown
Contributor Author

@ElpadoCan i also changed many other things including segmentation tool behaviors, maybe i should open a fresh pr draft, i also didn't test with fluorescent channels, did you load just the fluorescent channel or its mask as well

@ElpadoCan

ElpadoCan commented May 26, 2026

Copy link
Copy Markdown
Collaborator

What should be done is to add the lut_items on the same layout as the base layer lut_item on the left-hand side of the volume renderer.

Also, the code logic is now pretty complex. Especially in gui.py. I think we need some higher-level APIs, something like this

renderer = VolumeRenderer3DWindow()
renderer.set_volumes(zstacks)
renderer.set_overlay_segm_data(labels)
renderer.show()

@ElpadoCan

Copy link
Copy Markdown
Collaborator

Hi @keejkrej, I'm closing this because development of this feature continues in PR #1120. Feel free to comment there if you have any suggestions. Thanks!

@ElpadoCan ElpadoCan closed this Jun 15, 2026
@ElpadoCan ElpadoCan mentioned this pull request Jun 15, 2026
12 tasks
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.

2 participants