CSOBoolOp

MLModule

genre

CSOModificator

author

Grzegorz Chlebus

package

FMEstable/ReleaseMeVis

dll

MLCSOBoolOp

definition

MLCSOBoolOp.def

keywords

cso, bool, union, difference, intersection

Purpose

Perform boolean operations on input CSOList.

Details

All CSOs from inCSOList0 and inCSOList1 should be closed, in-plane, not self-intersecting and parallel to each other.

CSOs within one CSOList are treated as if they belonged to one structure, i.e. inner CSOs are treated as holes.

Windows

Default Panel

../../../Projects/MLCSOBoolOp/Modules/mhelp/Images/Screenshots/CSOBoolOp._default.png

Input Fields

inCSOList1

name: inCSOList1, type: CSOList(MLBase)

Second input for CSOs.

For accessing this object via scripting, see the Scripting Reference: MLCSOListWrapper.

inCSOList0

name: inCSOList0, type: CSOList(MLBase)

First input for CSOs.

For accessing this object via scripting, see the Scripting Reference: MLCSOListWrapper.

Output Fields

outCSOList

name: outCSOList, type: CSOList(MLBase)

Output for the result of the boolean operation.

For accessing this object via scripting, see the Scripting Reference: MLCSOListWrapper.

Parameter Fields

Field Index

[]: Trigger

inSkipSelfIntersectionTest: Bool

Unprocessed CSO IDs: String

Add output CSOs to CSOGroup: Bool

Min area factor: Double

Update: Trigger

Allowed plane distance: Double

On Input Change Behavior: Enum

Angle epsilon: Double

Operation: Enum

Clear: Trigger

PathPoint color: Color

CSOGroup label: String

Skip CSOs on error: Bool

doNotClearOnFailedUpdate: Bool

Status Code: Enum

Has Valid Output: Bool

Status Message: String

Visible Fields

Update

name: update, type: Trigger

Initiates update of all output field values.

Clear

name: clear, type: Trigger

Clears all output field values to a clean initial state.

On Input Change Behavior

name: onInputChangeBehavior, type: Enum, default: Clear, deprecated name: shouldAutoUpdate,shouldUpdateAutomatically

Declares how the module should react if a value of an input field changes.

Values:

Title

Name

Deprecated Name

​Update

​Update

​TRUE

​Clear

​Clear

​FALSE

Status Code

name: statusCode, type: Enum, persistent: no

Reflects module’s status (successful or failed computations) as one of some predefined enumeration values.

Values:

Title

Name

​Ok

​Ok

​Invalid input object

​Invalid input object

​Invalid input parameter

​Invalid input parameter

​Internal error

​Internal error

Status Message

name: statusMessage, type: String, persistent: no

Gives additional, detailed information about status code as human-readable message.

Has Valid Output

name: hasValidOutput, type: Bool, persistent: no

Indicates validity of output field values (success of computation).

[]

name: updateDone, type: Trigger, persistent: no

Notifies that an update was performed (Check status interface fields to identify success or failure).

Angle epsilon

name: inAngleEpsilon, type: Double, default: 0.001, minimum: 0, maximum: 1, deprecated name: inEpsilon

Epsilon used to test whether CSOs are in same plane. The test whether cso0 and cso1 are in same plane is as follows:

  1. if cso0 or cso1 is not planar, return false

  2. n0 <- normal vector of cso0, n1 <- normal vector of cso1

  3. if abs(n0 dot n1) <= 1 - epsilon, return false

  4. p0 <- first seed point of cso0, p1 <- first seed point of cso1

  5. if abs((p0 - p1) dot n0) >= epsilon, return false

  6. return true

Allowed plane distance

name: inMinPlaneDistanceInMM, type: Double, default: 0.0001, minimum: 0

Plane distance used to test wheter CSOs are in same plane.

Min area factor

name: inMinAreaFactor, type: Double, default: 0, minimum: 0, maximum: 1

Factor in range of [0, 1] used for postprocessing of bool op results on each plane. All resulting CSOs on a given plane having area smaller than A*minAreaFactor, where A is the total area of all input CSOs on the given plane, are removed.

Operation

name: inOperation, type: Enum, default: UNION

Select boolean operation to be performed on input CSOLists.

Values:

Title

Name

Description

​Diff

​DIFF

​:field:inCSOList0 \ inCSOList1

​Union

​UNION

​:field:inCSOList0 || inCSOList1

​Intersection

​INTERSECTION

​:field:inCSOList0 && inCSOList1

​Sym Difference

​SYM_DIFFERENCE

​:field:inCSOList0 xor inCSOList1

PathPoint color

name: inPathPointColor, type: Color, default: 0.8 0.4 0

Choose color of output CSOs’ path points.

Add output CSOs to CSOGroup

name: inAddOutputToCSOGroup, type: Bool, default: TRUE

Add output CSOs to a CSOGroup.

CSOGroup label

name: inOutCSOGroupLabel, type: String

Set the label of the output CSOGroup.

Skip CSOs on error

name: inSkipCSOsOnError, type: Bool, default: FALSE

When enabled, then CSOs causing errors won’t be processed.

Unprocessed CSO IDs

name: outUnprocessedCSOIDs, type: String, persistent: no

Unprocessed CSO IDs in the following format: (1,2,3:1)(4:2), meaning that CSOs with ID 1, 2 and 3 from the inCSOList0 couldn’t be processed together with CSO with ID 1 from the inCSOList1 and CSO with ID 4 from inCSOList0 couldn’t be processed with CSO with ID 2 from inCSOList1.

Hidden Fields

doNotClearOnFailedUpdate

name: doNotClearOnFailedUpdate, type: Bool, persistent: no

Prevents automated clear after update failed. This does not affect status fields. It enables the developer to analyze module’s state after failure.

inSkipSelfIntersectionTest

name: inSkipSelfIntersectionTest, type: Bool, default: FALSE