Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exporting a segmentation as a .stl generates the normal vectors backwards (inside-out) #158

Open
egravante opened this issue Jan 8, 2025 · 3 comments

Comments

@egravante
Copy link

(Running ITKSnap Version 4.2.2 on Windows)

Unfortunately, when exporting a segmentation as a .stl surface mesh, the normal vector that defines the "inside" and "outside" of the faces of the mesh is backwards. This leads to some weird compatibility issues when trying to read the files in other programs like GMSH.

This can be visualised in Blender.
File > Import > file.stl
Select "Show Overlays" in the top right corner of the window (the icon is two circles and not visible in edit mode), then check the "face orientation" box.
image
All of the red faces should be on the inside of the mesh.

Here is what it should look like: (fixed in Blender)
image

Thank you!

@pyushkevich
Copy link
Owner

Could you please share the segmentation file to help recreate?

@egravante
Copy link
Author

Yes absolutely!
R1053_Segmentation_NoBones.zip

@pyushkevich
Copy link
Owner

Fixed in commit e6af460

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

No branches or pull requests

2 participants