Skip to content

fix(ImageMapper): check cardinal neighbors in label outline border detection#3481

Merged
finetjul merged 1 commit intoKitware:masterfrom
PaulHax:label-outline-cardinal-neighbors
Apr 12, 2026
Merged

fix(ImageMapper): check cardinal neighbors in label outline border detection#3481
finetjul merged 1 commit intoKitware:masterfrom
PaulHax:label-outline-cardinal-neighbors

Conversation

@PaulHax
Copy link
Copy Markdown
Collaborator

@PaulHax PaulHax commented Apr 12, 2026

The label outline border detection loop used if (i == 0 || j == 0) which skips all cardinal-direction neighbors (up/down/left/right), only checking diagonals. Changed to if (i == 0 && j == 0) to skip only the center pixel.

Fixes #3480

…tection

The label outline border detection loop used `if (i == 0 || j == 0)`
which skips all cardinal-direction neighbors (up/down/left/right),
only checking diagonals. Changed to `if (i == 0 && j == 0)` to skip
only the center pixel, matching ImageResliceMapper's correct behavior.

Fixes Kitware#3480
Copy link
Copy Markdown
Collaborator

@daker daker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@finetjul finetjul added this pull request to the merge queue Apr 12, 2026
Merged via the queue into Kitware:master with commit 70bc9fa Apr 12, 2026
2 checks passed
@github-actions
Copy link
Copy Markdown

🎉 This PR is included in version 35.7.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions github-actions bot added the released Automated label label Apr 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released Automated label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] WebGL ImageMapper label outline skips cardinal direction neighbor checks

3 participants