Skip to content

Comments

v2.0.0-rc: Modernized core, revamped 3D visualization, and a richer set of command-line tools#975

Draft
chdinh wants to merge 195 commits intomainfrom
v2.0-dev
Draft

v2.0.0-rc: Modernized core, revamped 3D visualization, and a richer set of command-line tools#975
chdinh wants to merge 195 commits intomainfrom
v2.0-dev

Conversation

@chdinh
Copy link
Member

@chdinh chdinh commented Feb 22, 2026

Summary

This PR merges the v2.0-dev line into main, bringing the project to the v2.0 baseline: Qt6 + modern toolchain, a major 3D visualization refactor replacing legacy Qt3D usage, and an expanded set of command-line / offline tools beyond the classic GUI apps.

Major changes

1. Build & platform modernization

Update build baseline (CMake-based, C++20) and raise minimum build requirements (Qt6, modern compilers).

Centralize Qt component discovery to reduce repeated find-package warnings and streamline subproject configuration.

2. Qt3D refactor → disp3D_rhi (Qt6 RHI-based 3D renderer)

Replace the previous disp3D (Qt3D-based) library with disp3D_rhi, built on Qt6 RHI (QRhi) and compiled shader assets.

disp3D_rhi requires Qt6::GuiPrivate for QRhi headers; if unavailable, the library is skipped (explicit guard in CMake).

Applications depending on 3D inspection are conditionally built only if mne_disp3D_rhi is present.

3. Expanded application & CLI tool surface

In addition to the existing core apps (mne_scan, mne_analyze, mne_anonymize, mne_rt_server, mne_forward_solution, mne_edf2fiff, mne_dipole_fit), v2.0-dev adds/extends build targets for additional utilities:

New/added apps/tools: mne_browse, mne_inspect, mne_show_fiff, mne_compute_raw_inverse, mne_setup_mri, mne_surf2bem, mne_setup_forward_model, plus FreeSurfer-gated tools mne_watershed_bem and mne_flash_bem.

Introduce FreeSurfer detection at configure time and only build watershed/flash BEM tools when FreeSurfer is available.

Notable internal/library structure updates

Library set now includes additional components compared to main (e.g., lsl, mri, and disp3D_rhi), aligning with the new runtime + visualization and device/streaming capabilities.

Breaking / migration notes

Qt6 upgrade and updated compiler baselines are required for building main after merge.

3D rendering stack changed from Qt3D-era implementation to the new RHI-based pipeline (disp3D_rhi); downstream integrations relying on old disp3D internals may need adjustment.

Testing

CI should validate the new baseline; locally: cmake -S . -B build && cmake --build build (per updated build guidance).

chdinh added 30 commits January 30, 2026 22:05
…ne settings and a rewritten fragment shader for Fresnel effects and additive blending.
…ses and the `v2.0-dev` branch for development releases.
@LorenzE
Copy link
Member

LorenzE commented Feb 22, 2026

Wow — this is a massive contribution 🚀 It’s honestly exciting to see this project waking up from hibernation again. I really like what you did with the documentation. And porting over more of Matti’s code was a great move. The new 3D stuff looks amazing 👏 I still sometimes struggle to fully wrap my head around agentic workflows these days 😅 — and I honestly can’t believe how much time I spent implementing the first version of the disp_3d library back then.

3000+ files is definitely no small change 😄 But given that the project has been more or less in archive mode, I’m absolutely fine moving forward with this PR. I obviously didn’t review every single line (that would take a while), but overall I really appreciate the direction and the energy you’re putting into this.

I do have a couple of questions/comments:

  • Why wasn’t the old Eigen version removed?
  • What was the reasoning behind bringing back mne_browse? If I remember correctly, mne_analyze already covered browsing functionality 🤔
  • For the new CLI applications: are the tests only checking whether output files are created, or do they also validate correctness (e.g., against reference outputs)?

@agramfort
Copy link
Member

thx claude code haha ;)

glad to see you folks still around 🤗

@chdinh
Copy link
Member Author

chdinh commented Feb 22, 2026

Thanks both — really appreciate the quick review (and the encouragement). Given the size, I’m glad you’re comfortable moving this forward.

@LorenzE — quick answers:

  • Eigen: the intent was to fully move to Eigen 5.0.0 and remove the old vendored version. If anything old is still lingering, that’s on me — I’ll re-check and clean it up so we don’t carry two versions.
  • Why mne_browse again: agree mne_analyze covers browsing; the goal is a lean, simple triage tool for dataset standardization (mark bad channels/segments) with few options and fewer ways to make mistakes, so non-/low-code colleagues can use it safely. Longer-term I’d like to add a headless mode for scripted/agentic preprocessing.
  • CLI tests: mixed. Where possible we validate numerics against mne-python (we already fixed one mismatch around default baseline correction). For FreeSurfer-dependent tools, CI avoids requiring FreeSurfer, so those are currently closer to smoke tests than full reference validation.

@agramfort — haha 😄 great to be back 🤗 and indeed - next: SKILLS… MNE_SKILL 😉

@lorenz-esch-bl
Copy link

lorenz-esch-bl commented Feb 23, 2026

@chdinh Please also update the required checks for PRs int repo's branch protection rules.

Regarding the removal of the old Eigen version: My bad it looks like everything old has been removed already :)

@chdinh
Copy link
Member Author

chdinh commented Feb 23, 2026

@LorenzE am I seeing this correctly? Since the pipelines were rewritten as well, we should probably merge into main to remove the old pipeline definitions.

@chdinh chdinh marked this pull request as draft February 23, 2026 16:41
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.

4 participants