---
name: "SoBoolOperation"
section: "3iv"
platform: "linux"
package: "inventor-doc"
version: "2.1.6+ds-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/SoBoolOperation/3iv"
---

# SoBoolOperation(3iv)

performs Boolean operations

## NAME

SoBoolOperation — performs Boolean operations

## INHERITS FROM

SoBase \> SoFieldContainer \> SoEngine \> SoBoolOperation

## SYNOPSIS

**#include \<Inventor/engines/SoBoolOperation.h\>**

**enum Operation {** **SoBoolOperation::CLEAR**

**SoBoolOperation::SET**

**SoBoolOperation::A**

**SoBoolOperation::NOT\_A**

**SoBoolOperation::B**

**SoBoolOperation::NOT\_B**

**SoBoolOperation::A\_OR\_B**

**SoBoolOperation::NOT\_A\_OR\_B**

**SoBoolOperation::A\_OR\_NOT\_B**

**SoBoolOperation::NOT\_A\_OR\_NOT\_B**\

**SoBoolOperation::A\_AND\_B**

**SoBoolOperation::NOT\_A\_AND\_B**

**SoBoolOperation::A\_AND\_NOT\_B**

**SoBoolOperation::NOT\_A\_AND\_NOT\_B**\

**SoBoolOperation::A\_EQUALS\_B**

**SoBoolOperation::A\_NOT\_EQUALS\_B**\

**}**

Inputs from class SoBoolOperation:

**SoMFBool**	**a**\
 **SoMFBool**	**b**\
 **SoMFEnum**	**operation**

Outputs from class SoBoolOperation:

**(SoMFBool)**	**output**\
 **(SoMFBool)**	**inverse**

Methods from class SoBoolOperation:

	**SoBoolOperation()**

Methods from class SoEngine:

**static SoType**	**getClassTypeId()**\
 **virtual int**	**getOutputs(SoEngineOutputList &list) const**\
 **SoEngineOutput \***	**getOutput(const SbName &outputName) const**\
 **SbBool**	**getOutputName(const SoEngineOutput \*output, SbName &outputName) const**\
 **SoEngine \***	**copy() const**\
 **static SoEngine \***	**getByName(const SbName &name)**\
 **static int**	**getByName(const SbName &name, SoEngineList &list)**

Methods from class SoFieldContainer:

**void**	**setToDefaults()**\
 **SbBool**	**hasDefaultValues() const**\
 **SbBool**	**fieldsAreEqual(const SoFieldContainer \*fc) const**\
 **void**	**copyFieldValues(const SoFieldContainer \*fc, SbBool copyConnections = FALSE)**\
 **SbBool**	**set(const char \*fieldDataString)**\
 **void**	**get(SbString &fieldDataString)**\
 **virtual int**	**getFields(SoFieldList &resultList) const**\
 **virtual SoField \***	**getField(const SbName &fieldName) const**\
 **SbBool**	**getFieldName(const SoField \*field, SbName &fieldName) const**\
 **SbBool**	**isNotifyEnabled() const**\
 **SbBool**	**enableNotify(SbBool flag)**

Methods from class SoBase:

**void**	**ref()**\
 **void**	**unref() const**\
 **void**	**unrefNoDelete() const**\
 **void**	**touch()**\
 **virtual SoType**	**getTypeId() const**\
 **SbBool**	**isOfType(SoType type) const**\
 **virtual void**	**setName(const SbName &name)**\
 **virtual SbName**	**getName() const**

## DESCRIPTION

**This engine performs a Boolean operation on two inputs, and returns both the result of the operation and its inverse.**

**The input fields can have multiple values, allowing the engine to perform several Boolean** **operations in parallel. One input may have more values than the other. In that case, the last value of the shorter input will be repeated as necessary.**

## INPUTS

**SoMFBool**	**a**\
 First argument to the Boolean operation.

**SoMFBool**	**b**\
 Second argument to the Boolean operation.

**SoMFEnum**	**operation**\
 The Boolean operation.

## OUTPUTS

**(SoMFBool)**	**output**\
 Result of the Boolean operation applied to the inputs.

**(SoMFBool)**	**inverse**\
 Inverse of **output**.

## METHODS

	**SoBoolOperation()**\
 Constructor.

## FILE FORMAT/DEFAULTS

```
BoolOperation {
a	FALSE
b	FALSE
operation	A
}
```

## SEE ALSO

**SoEngineOutput, SoCalculator**
