SoWEMDiagnosis¶
-
InventorModule
¶ genre WEMInformation
author MeVis Medical Solutions AG
package MeVisLab/Standard
dll SoWEM
definition SoWEM.def see also WEMInfo
keywords error
,warning
,check
Purpose¶
The SoWEMDiagnosis
runs a full diagnostics on the input WEM and reports the resulting errors both as an Open Inventor scene and as a short and detailed list on its panel.
Usage¶
Just plug a WEM into the input. Optionally plug in the Open Inventor output to any 3D Viewer, together with the output of a SoWEMRenderer module.
Details¶
The main panel consists of four major parts.
- On the left an overview of all errors, warnings, and notices with a short description of the occurred error is displayed.
- On the top right Display Options are shown, which allow for filtering warnings and notices.
- Below these Display Options is detailed information about the selected primitive.
- At the bottom a status bar shows the total amount of errors, warnings, and notices and a global status of the input WEM.

As can be seen, each type of error has a different color indicating a different severity level of the error.
Icon | Meaning |
---|---|
![]() |
FATAL ERROR Other WEM modules using this mesh will not work (best-case scenario) but most likely, the module will crash or cause a segmentation fault. Fatal errors include double-linked primitives and invalid edges/faces. |
![]() |
ERROR Although not fatal to other WEM modules, these errors are still severe enough to cause modules to fail. Errors include non-connected primitives, inverted normals, and invalid edge pointers. |
![]() |
WARNING As the name suggests, these indicate certain issues about the mesh that should better be fixed if one wants to archive a perfect WEM. Warnings include orphan/redundant nodes, zero-length edges, and zero-area faces. |
![]() |
NOTICE These are totally harmless! Notices include boundaries, flat regions, and concave faces. |
Each entry in the list can be selected, upon which more information about the error and primitive are shown at the right side of the panel. Use the display options to limit the amount of warnings and/or notices that are shown. This applies to both the displayed list and the Open Inventor scene. Using the settings button at the bottom right, one can also enable the merging of error messages into one single entry in the displayed list.
This is the full list of fatals, errors, warnings, and notices, and their meaning.
Nodes:
Icon | Message | Meaning |
---|---|---|
![]() |
Double Entry | The node has a double listing for an edge/face; removing the edge/face results in an invalid listing. |
![]() |
Non Connected | The node has an edge or face that is not connected to it. Either the node has an edge or face too many, or the relationship between both is otherwise broken. |
![]() |
Bad Normal Length | The node normal has a length different from 1. Since the node normal is calculated from the incident face normals, this means something is wrong with the surrounding faces. For instance, their area is zero, resulting in a normal (0,0,0) and as such resulting in a node normal (0,0,0). |
![]() |
Dead End | The node has only one edge. This does not represent a valid 2-manifold. |
![]() |
Orphan | The node has no incident edges nor faces. Since it has no link with the rest of the mesh, it can safely be removed. |
![]() |
Redundant/Collinear | The node has two incident edges and faces and can be removed. This is certainly the case if this node and the other nodes from the incident edges are also collinear. |
![]() |
Neighborhood Not Set | The node has no edges and is not an orphan, but the WEM itself claims to have egdes. Edge relationship for this node should be built. |
![]() |
Boundary | The node is part of an edge that has only one incident face, with the other being NULL, indicating a boundary. |
![]() |
Flat Region | The maximum angle between the node normal and the normals of the incident faces is less than one degree. |
![]() |
Valence 3 | The node has an edge valence of three, meaning there are three incident edges belonging to three incident triangles. Each edge is shared by two of these three triangles. This allows for merging these three triangles into one larger triangle. Nodes with a valence of three result in an undesirable triangle configuration and should be avoided whenever possible. |
Edges:
Icon | Message | Meaning |
---|---|---|
![]() |
NULL Head | The head of the winged-edge is NULL, making it an invalid edge. |
![]() |
NULL Tail | The tail of the winged-edge is NULL, making it an invalid edge. |
![]() |
NULL Pointer | One of this edge’s edge pointers (lPred, lSucc, rPred or rSucc) is NULL. This indicates an invalid or partially set edge neighborhood. |
![]() |
Equal Pointer | One of this edge’s edge pointers (lPred, lSucc, rPred or rSucc) is equal to another of those edge pointers. This is most likely the consequence of an illegal operation, which leaves the edge neighborhood broken or not updated. |
![]() |
Non Connected Pointer | One of this edge’s edge pointers (lPred, lSucc, rPred or rSucc) is not connected to either the head or tail of this edge. |
![]() |
Edge Pointer Link | One of this edge’s edge pointers (lPred, lSucc, rPred or rSucc) does not link back to this edge. |
![]() |
Circular Pointer | One of this edge’s edge pointers (lPred, lSucc, rPred or rSucc) points to this edge. |
![]() |
Order | The order of the edges for the left or right face of this edge are not in the correct order to belong to a left or right face. |
![]() |
Fold | The edge creates a fold on the mesh. Two incident faces of an edge are folding if their normals make an angle of approximate 180 degrees. |
![]() |
Zero Length | The edge has zero length. As a result, the triangles to which this edge belongs have an area of zero. |
![]() |
Neighborhood Not Set | The edge has no edge pointers (lSucc, lPred, rSucc and rPred), but the WEM itself claims to have edges. Edge relationship for this edge should be built. |
![]() |
Boundary | The edge is part of a boundary, having only one incident face and the other being NULL. |
Faces:
Icon | Message | Meaning |
---|---|---|
![]() |
NULL Node | The face has a node that is NULL. |
![]() |
NULL Edge | The face has an edge that is NULL. |
![]() |
Invalid | The amount of nodes and edges for this face differs. This does not represent a valid face. |
![]() |
Double Entry | The face has a double listing for a node/edge. Removing the node/edge results in an invalid listing. |
![]() |
Non Connected | The face has a node/edge that does not link back to this face. |
![]() |
Edge Offset | The order of nodes and edges for this face is not the same. Suppose i to be the index of the node in the nodes list of this face: node i and node i+1 are not part of edge i. This is required by a lot of WEM modules. |
![]() |
Normal Inverted | The normal is inverted. This only applies to (concave) faces where the normal was wrongfully calculated. |
![]() |
Zero Area | The face has a zero area. This also means at least one of the edges has a zero length. The face should be removed since it is not visible. |
![]() |
Bad Normal Length | The normal of the face has a length different from 1. This most likely results from having a zero area resulting in a normal (0,0,0) with length 0. |
![]() |
Neighborhood Not Set | The face has no edges, but the WEM itself claims to have edges. Edge relationship for this face should be built. |
![]() |
Concave | The face is concave. Actually, this should be avoided since rendering these faces may result in visual artifacts. |
Input Fields¶
inputWEM¶
-
name:
inputWEM
, type:
WEM(MLBase)
¶ The WEM to be diagnosed.
For accessing this object via scripting see the Scripting Reference:MLWEMWrapper
.
Output Fields¶
Parameter Fields¶
Field Index¶
Visible Fields¶
Alpha (nodeAlpha)¶
-
name:
nodeAlpha
, type:
Float
, default:
1
, minimum:
0
, maximum:
1
¶ Sets the alpha value for the rendered nodes.
Alpha (edgeAlpha)¶
-
name:
edgeAlpha
, type:
Float
, default:
1
, minimum:
0
, maximum:
1
¶ Sets the alpha value for the rendered edges.
Alpha (faceAlpha)¶
-
name:
faceAlpha
, type:
Float
, default:
0.40000001
, minimum:
0
, maximum:
1
¶ Sets the alpha value for the rendered faces.
Scale (scaleNodes)¶
-
name:
scaleNodes
, type:
Float
, default:
2
, minimum:
0.1
, maximum:
10
¶ Sets the scaling factor for the size of the displayed nodes.
Scale (scaleEdges)¶
-
name:
scaleEdges
, type:
Float
, default:
1
, minimum:
0.1
, maximum:
10
¶ Sets the scaling factor for the thickness of the displayed edges.
Elevation¶
-
name:
faceElevation
, type:
Float
, default:
0.1
¶ Sets how much the faces are elevated into the normal direction to enhance their visibility.
Show redundant nodes¶
-
name:
showRedundant
, type:
Bool
, default:
TRUE
¶ If checked, redundant nodes are detected and displayed.
Show collinear nodes¶
-
name:
showCollinear
, type:
Bool
, default:
TRUE
¶ If checked, collinear nodes are detected and displayed.
Show orphan nodes¶
-
name:
showOrphan
, type:
Bool
, default:
TRUE
¶ If checked, orphan nodes are detected and displayed.
Show flat regions¶
-
name:
showFlatRegion
, type:
Bool
, default:
TRUE
¶ If checked, flat regions (adjacent faces have the same normal) are detected and displayed.
Show boundaries¶
-
name:
showBoundary
, type:
Bool
, default:
TRUE
¶ If checked, boundaries are detected and displayed.
Show concave faces¶
-
name:
showConcave
, type:
Bool
, default:
TRUE
¶ If checked, concave faces are detected and displayed.
Show neighborhood not set¶
-
name:
showNeighborhood
, type:
Bool
, default:
TRUE
, deprecated name:
showNeighbourhood
¶ If checked, non-set neighborhood primitives (missing pointers) are detected and displayed.
Show zero-size primitives¶
-
name:
showZeroSize
, type:
Bool
, default:
TRUE
¶ If checked, zero-size primitives (faces and edges) are detected and displayed.
Show nodes with valence 3¶
-
name:
showValence3
, type:
Bool
, default:
TRUE
¶ If checked, nodes with a valence of 3 (three edges attached) are detected and displayed. Those nodes typically do not contribute to the overall geometry but spoil the rendering because of their contribution to the normal calculation.
Show duplicate nodes¶
-
name:
showDuplicateNodes
, type:
Bool
, default:
TRUE
¶ If checked, duplicate nodes (share the same position) are detected and displayed.
Show holes¶
-
name:
showHoles
, type:
Bool
, default:
TRUE
¶ If checked, holes are detected and displayed.
Show inverted¶
-
name:
showInverted
, type:
Bool
, default:
TRUE
¶ If checked, inverted faces are detected and displayed.
Max. Displayed Messages¶
-
name:
useMaxNumDisplayedErrors
, type:
Bool
, default:
TRUE
¶ If checked, the
Max Num Displayed Errors
is used to limit the amount of displayed single errors.