Add PaintModel module (MeshMixer-like model face labeling) - #1
Add PaintModel module (MeshMixer-like model face labeling)#1aabrown100-git wants to merge 8 commits into
Conversation
Extracted the face-group creation, brush-based selection, editing (expand, invert, clear, new group from selection), color visualization, and .vtp export tools that were built into the SurfaceToolbox 'Group faces' panel, and turned them into their own standalone module, PaintModel, with a dedicated always-visible panel.
|
@lassoan Should I ask anyone to review/test it, or can I just merge it? |
|
@lassoan @alisonmarsden @ktbolt Just checking if we want anyone to review this PR. |
|
@aabrown100-git I not familiar with Slicer so I probably can't do much of a review ! However, a couple of comments. Are developers not opening GitHub Issues for these new modules so other developers can comment on the proposed new additions ? iI seems that you have needed to use thus sort of Meshmixer capability for your research but it is not clear why you needed it and how you used it. How will the output of this module be used by the other SImVascular modules ? |
|
@ktbolt The utility of this tool is briefly stated in the linked issue under Current Situation, but you're right there should be a dedicated issue on this. Originally, I created this tool to be part of a different Slicer extension. I'm not exactly sure how this fits in with other SimVascular modules, but I think this tool should eventually live in the SimVascular Modeling module. I've reached out to members of the Slicer-SimVascular migration team to make sure they are aware of this. |
|
While the module could be enhanced and tailored to the needs of specific workflows, I think it is reasonable to add it to this extension as is, as an "Experimental" module (it could be a category in the top-level readme.md file). A couple of improvements that could be considered (these are just ideas, prioritization should be driven by actual modeling workflow needs):
|
|
@aabrown100-git I was initially thinking that the capabilities of this tool should be added to the SimVascular Modeling module but now I'm wondering about how to best manage the complexity (GUI controls and core compute code) of SimVascular Modules. When I worked on AVS we implemented modules to be as lean as possible, doing one thing, making them easier to maintain and test. Maybe it would be good to consider the |
|
There can be multiple level of modules:
PaintModel is a low-level tool that can be used as is for experimenting; and it could be used in the future by workflow modules. |
Current situation
https://github.com/JolleyLab/SlicerHeart-Simvascular-Private/issues/22#issuecomment-5027649601
Release Notes
Adds Paint Model, a new scripted module for interactively painting,
grouping, and exporting face regions on surface models. The workflow —
auto-partition by dihedral angle, then merge, brush-paint, and edit groups
by hand — is inspired by Meshmixer's face-group tools.
Features
merging small groups into their largest shared-boundary neighbor.
S/D+ drag to select/deselect;Gexpand to groups,Iinvert,Nnew group from selection,Cclear..vtpwith aModelFaceIDcell array.Video showing available features, in order
Screen.Recording.2026-07-23.at.11.03.03.AM.mov
7/30/26 Update: After making some performance optimizations (d4431b5), the interactivity of Brush select is much better than shown in the above video. Now, there is basically no perceptible latency.
Changes
PaintModel/— new module (widget, logic, tests)CMakeLists.txt— register the moduleREADME.md,Docs/PaintModel.md— docs and tutorialDocumentation
Documentation is added in the extension
README.mdanddocs/PaintModel.md.Testing
PaintModel functionality was test using a local Slicer installation (Slicer 5.10.0 on 2026 MacBook Pro M5 Pro, MacOS Tahoe 26.5.2)
Code of Conduct & Contributing Guidelines