Repository navigation
Step 2: clip loop-closure target preview by intersection slab - #587
Merged
Merged
Conversation
In loop closure "Manipulate active edge" mode the blue target scans were drawn without the xz/yz/xy intersection flags, so they ignored the slab while the red source was clipped. The point shader also tested the slab (and Elevation/Distance gradients) against the cached position, with the preview delta folded only into the MVP, so a moved preview would be clipped at its stored pose. Apply the delta as a separate model matrix before fragWorldPos instead; this also fixes "Show with initial pose" and step 3's posed session previews. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
In step 2's loop closure mode with Manipulate active edge on, the blue (target) cloud ignored the xz/yz/xy intersection slab. The red (source) cloud was clipped as expected.
Cause
ScanRenderer::drawCachedWithTransform()but did not pass the intersection flags, so they defaulted to off.Fix
xz/yz/xy_intersectionandintersection_widthto the target preview draw.modeluniform to the point shader, applied beforefragWorldPos. The pose delta goes there instead of into the MVP. All four shader users (draw,drawCachedWithTransform,drawPoints,drawTrajectories) set it, since an unsetmat4uniform is zero.Side effects (corrections): "Show with initial pose" in step 2 and step 3's posed session previews now clip and colour by the displayed position.
Testing
🤖 Generated with Claude Code