WEMClip

MLModule
genre WEMProcessing
status stable
authors Olaf Konrad, Bart De Dobbelaer
package MeVisLab/Standard
dll MLWEMModules
definition MLWEMModules.def
see also WEMBoolOp
keywords WEM, plane

Purpose

The module WEMClip clips a WEM according to a given plane and generates CSOs that represent an intersection of a WEM and a plane.

Usage

Connect any WEM to the input of the WEMClip module, choose a plane and click the apply button.

Details

Clipping (also known as culling) is a very common operation in 3D graphics. When viewing a 3D scene, all 3D meshes falling outside the user's view or only partly visible need to be clipped against the viewing frustum. In comparison with such a frustum, which has six clipping planes, the WEMClip module only has one. It intersects the WEM and each face either lies on the interior side or exterior side of the plane.

A smaller portion of the 3D mesh faces intersect the clipping plane. Depending on how the interior and exterior of the clipping plane are defined, some part of the WEM is kept, while the other faces are discarded. The faces intersecting the plane change their geometry since one, two, three or more nodes become invisible.

Windows

Default Panel

../../../Modules/ML/MLWEMModules/mhelp/Images/Screenshots/WEMClip._default.png

Input Fields

inWEM

name: inWEM, type: MLBase

Output Fields

The clipped WEM and a CSO for the clipped path (can be more than a single CSO).

outWEM

name: outWEM, type: MLBase

outCSOList

name: outCSOList, type: MLBase

Parameter Fields

Visible Fields

Auto Apply

name: autoApply, type: Bool, default: TRUE

If checked, all changes of parameters lead to a new clipping of the input WEM.

Auto Update

name: autoUpdate, type: Bool, default: TRUE

If checked, all changes to the input WEM leads a new clipping.

Apply

name: apply, type: Trigger

If pressed, the input WEM is clipped against the plane.

Triangulation Mode

name: triangulationMode, type: Enum, default: Strip

Defines the triangulation mode.

Values:

Title Name Description
Center node Center node A new node is added to the center of the polygon.
Fan Fan From one node (the first one), edges are generated to all other nodes of the polygon.
Strip Strip Nodes on opposing sides are connected by edges.

Plane

name: plane, type: Plane, default: 0 0 1 0

Sets the clipping plane, given by its planar equation Ax+By+Cz+D = 0.

Generate Edges

name: generateEdges, type: Bool, default: TRUE

If checked, edges are generated on the output meshes.

If edges are not required for the rest of the pipeline, unchecking this option saves time.

Generate CSOs

name: generateCSOs, type: Bool, default: TRUE

If checked, CSOs are generated on the output. Generation of CSOs require edges.

Which Output

name: whichOutput, type: Enum, default: Inner

Deinfes which output mesh is generated.

By default both parts of the clipped WEM are generated, but either half can be chosen.

Values:

Title Name
Both Both
Inner Inner
Outer Outer

Hidden Fields

isProcessing

name: isProcessing, type: Bool, default: FALSE

elapsedTime

name: elapsedTime, type: Float, default: 0

id

name: id, type: Integer, default: 0

autoClear

name: autoClear, type: Bool, default: FALSE

removePreviousWEMs

name: removePreviousWEMs, type: Bool, default: TRUE

show

name: show, type: Bool, default: TRUE

editable

name: editable, type: Bool, default: TRUE

useFaceDiffuseColor

name: useFaceDiffuseColor, type: Bool, default: TRUE

usePolygonOffset

name: usePolygonOffset, type: Bool, default: FALSE

copyInputWEMs

name: copyInputWEMs, type: Bool, default: FALSE

listenToFinishNotifications

name: listenToFinishNotifications, type: Bool, default: TRUE

forwardRepaintNotifications

name: forwardRepaintNotifications, type: Bool, default: TRUE

forwardSelectionNotifications

name: forwardSelectionNotifications, type: Bool, default: TRUE

progress

name: progress, type: Float, persistent: no

useInputWEMToCreateOutputWEM

name: useInputWEMToCreateOutputWEM, type: Bool, persistent: no

modifyAttributes

name: modifyAttributes, type: Bool, default: FALSE

invalidPathPointColor

name: invalidPathPointColor, type: Color, default: 1 0.666670024394989 0

invalidMarkerColor

name: invalidMarkerColor, type: Color, default: 1 0 0

generateCSOsOpen

name: generateCSOsOpen, type: Bool, default: FALSE

autoLevelCSOs

name: autoLevelCSOs, type: Bool, default: TRUE

outputTabSelected

name: outputTabSelected, type: Bool, default: TRUE