Class SoMFBitMask<EnumType extends Enum<EnumType> & IntegerValuedEnum>
The bit-wise "&" and "|" operators should be used when testing and setting flags in a mask.
SoMFBitMasks are written to file as one or more mnemonic enumerated type names, in this format:
If only one flag is used in a mask, the parentheses are optional. These names differ among uses of this field in various node or engine classes. See the reference pages for specific nodes or engines for the names.( flag1 | flag2 | ... )
The field values may also be represented as integers, but this is not guaranteed to be portable.
When more than one value is present, all of the values are enclosed in square brackets and separated by commas.
Data copying:
SoMF fields are a kind of "smart container", automatically expanding as necessary to hold the data provided by the application. This is very convenient, but for large blocks of data it may be desireable to avoid making a copy of the application data. The setValuesBuffer() methods allow Open Inventor to directly use an array of values supplied by the application. The application data is not copied. Please see SoMFVec3f
for more information and example code.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.openinventor.inventor.fields.SoField
SoField.FieldTypes
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
Field Summary
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
Constructor Summary
ConstructorsConstructorDescriptionSoMFBitMask
(SoFieldContainer fieldContainer, String fieldName, SoField.FieldTypes fieldType, Class<EnumType> enumClass) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
setValuesBuffer
(ByteBuffer userData) Sets the field to contain the values stored in userData.Methods inherited from class com.openinventor.inventor.fields.SoMFEnum
disableDeleteValues, equals, find, find, finishEditing, getDirectValues, getValueAt, getValues, set1Value, set1Value, setValue, setValue, setValues, startEditing
Methods inherited from class com.openinventor.inventor.fields.SoMField
deleteValues, deleteValues, get1, getNum, insertSpace, set1, setNum
Methods inherited from class com.openinventor.inventor.fields.SoField
appendConnection, appendConnection, connectFrom, connectFrom, disconnect, disconnect, disconnect, enableConnection, get, getConnectedEngine, getConnectedField, getContainer, getNumConnections, getValueSize, isConnected, isConnectedFromEngine, isConnectedFromField, isConnectedFromVRMLInterp, isConnectionEnabled, isDefault, isIgnored, set, setIgnored, touch
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
Constructor Details
-
SoMFBitMask
public SoMFBitMask(SoFieldContainer fieldContainer, String fieldName, SoField.FieldTypes fieldType, Class<EnumType> enumClass) Default constructor.
-
-
Method Details
-
setValuesBuffer
Sets the field to contain the values stored in userData. This data will not be copied into the field: it will be directly used by the field.- Overrides:
setValuesBuffer
in classSoMFEnum<EnumType extends Enum<EnumType> & IntegerValuedEnum>
-