Skip to content

Remove the multi-head voxel export path that never runs - #209

Merged
vycdev merged 3 commits into
developfrom
chore/remove-dead-voxel-reconstruction
Nov 20, 2026
Merged

vycdev merged 3 commits into
developfrom
chore/remove-dead-voxel-reconstruction

Conversation

@vycdev

@vycdev vycdev commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

The v4.3.0 release review found that the 3MF exporter's multi-head voxel reconstruction never runs in the app. It only kicks in for meshes that have both userData.nozzleIndex and kromacutExportGeometry.activePixels. No production mesh has both. Multi-head meshes deliberately keep only {positions, indices}, and Flat Paint parts have pixels but no nozzle. So every real export already wrote one closed part per region and layer. The comment claiming "one manifold voxel solid per nozzle" was wrong. Multi-head progress also sat on an idle 0–20% span.

This removes the dead path and the code that only it used:

  • buildNozzleManifoldMeshes, src/lib/voxelMesh.ts, and its tests.
  • The reserved progress span. Multi-head export progress now matches single-head progress.
  • The preserveVertexIndices flag, which nothing sets any more. Nozzle-tagged meshes still keep their source vertex indexing.
  • The test-only mesher options skipBottomCap, skipRepair, and combinedMask. The only production caller, ThreeDView, never passes them.

Tests that only exercised those paths are gone. A new test checks that multi-head export reports the same progress as single-head export; it fails on develop. A short clause is folded into the unreleased Multi-head printing changelog bullet for the progress change. The "Multi-extruder 3MF export" changelog bullet no longer describes the deleted voxel meshes and mesher options. That bullet sits under v4.2.0, although v4.2.0 never shipped it; moving it is left as a follow-up.

Proof:

  • Exported multi-head 3MF bytes are unchanged. I hashed every file in the archive (SHA-256) for meshes built by the real generateMultiHeadMeshes: strengths none and medium, pixel sizes 0.01 and 0.4 mm, 4×4 and 48×48 images. All 8 hashes match before and after.
  • Greedy and smooth mesher positions and indices are unchanged for all strengths, on masks up to 200×200.
  • npm run lint, npm run build, and npm test pass (1136 pass, 0 fail, plus the existing Windows-only skip), including the meshing, 3MF, and multi-head topology tests.
  • test:e2e:all passes: all 8 suites, 223 tests.

Reviewed with sol-loop: 1 round with gpt-6.2-sol. Sol verdict: approved (two comment and fixture nits applied).

Council review

Rounds: 3. Both members confirmed independently, against an extracted base, that exported 3MF bytes and mesher output are unchanged.

Delegate Round 1 Round 2 Round 3
Claude Opus 5.5 9/10 8/10 9/10
GPT-6.2 Sol 9/10 9/10 10/10

Created with Claude Opus 5.5 in Claude Code (T3 Code).

🤖 Generated with Claude Code

@vycdev
vycdev force-pushed the chore/remove-dead-voxel-reconstruction branch 2 times, most recently from 7be9382 to 7f3adfc Compare November 20, 2026 14:46
vycdev and others added 3 commits November 20, 2026 17:05
The per-nozzle voxel reconstruction in the 3MF exporter only ran for meshes
carrying both nozzleIndex and activePixels, which no production mesh has, so
every export fell through to the per-region path. Remove it with voxelMesh.ts,
its idle progress span, the unset preserveVertexIndices flag, and the
test-only mesher options skipBottomCap/skipRepair/combinedMask.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…log entry

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vycdev
vycdev force-pushed the chore/remove-dead-voxel-reconstruction branch from 7f3adfc to 9f7d80c Compare November 20, 2026 15:05
@vycdev
vycdev merged commit 217a419 into develop Nov 20, 2026
14 checks passed
vycdev added a commit that referenced this pull request Nov 20, 2026
Merge the four Open in Slicer bullets into one entry for the shipped
flow, fold Multi-head filament requirements into Multi-head printing,
and move the decode-once image work into its own Changed entry. Move
touch-up history fixes that predate v4.3 into Fixed, add the missing
diagnostics folder fix, and reduce the cats benchmark entry to one
Fixed line. Fold in the notes from PRs merged since (#203, #205, #206,
#208, #209, #210, #212, #213) and trim test-only and maintenance
details that do not help users.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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