If I create a surface with ManualSegmentationToSurfaceFilter then the surface normals are not computed, or at least they are not rendered correctly.
Reproducing the issue:
- Build the example plugins.
- Open a 3D image and calculate the surface with the ISO Surface view.
- Rotate the surface by mouse dragging in the 3D render window.
You will see that the dark and light side of the object remains the same, although the object should be enlightened from the front always.
However, if you save the surface in stl format and then open the file, the surface is rendered correctly.
Saving the image in vtk/vtp format did not solve the problem, I attached a fix for this. (It also fixes a potential memory leak, a Delete() invocation was put in a wrong place.)
But I could not figure out how to display the correct surface without saving and reopening the image.