SoMFBitMask Class Reference
[Fields]

Multiple-value field containing any number of masks of bit flags. More...

#include <Inventor/fields/SoMFBitMask.h>

Inheritance diagram for SoMFBitMask:
SoMFEnum SoMField SoField SoTypedObject

List of all members.

Public Member Functions

virtual SoType getTypeId () const
const SoMFBitMaskoperator= (const SoMFBitMask &f)
 SoMFBitMask ()
virtual ~SoMFBitMask ()
int operator= (int newValue)
void setValuesPointer (int num, const int *userData)
void setValuesPointer (int num, int *userData)

Static Public Member Functions

static SoType getClassTypeId ()

Detailed Description

Multiple-value field containing any number of masks of bit flags.

A multiple-value field that contains any number of masks of bit flags, stored as ints. Nodes or engines that use this field class define mnemonic names for the bit flags. These names should be used when setting or testing the values of the field, even though the values are treated as integers in the methods.

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:

      ( flag1 | flag2 | ... )
     

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.

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 setValuesPointer() 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.

Constructor & Destructor Documentation

SoMFBitMask::SoMFBitMask (  ) 

Default constructor.

virtual SoMFBitMask::~SoMFBitMask (  )  [virtual]

Destructor.


Member Function Documentation

static SoType SoMFBitMask::getClassTypeId (  )  [static]

Returns the type identifier for this class.

Reimplemented from SoMFEnum.

virtual SoType SoMFBitMask::getTypeId (  )  const [virtual]

Returns the type identifier for this specific instance.

Reimplemented from SoMFEnum.

int SoMFBitMask::operator= ( int  newValue  )  [inline]

Sets this field to newValue.

Reimplemented from SoMFEnum.

const SoMFBitMask& SoMFBitMask::operator= ( const SoMFBitMask f  ) 

Copy from another field of same type.

Reimplemented from SoMFEnum.

void SoMFBitMask::setValuesPointer ( int  num,
int *  userData 
)

See setValuesPointer(int, const int *).

Reimplemented from SoMFEnum.

void SoMFBitMask::setValuesPointer ( int  num,
const int *  userData 
)

Sets the field to contain the num values stored in userData array.

This array will not be copied into the field: it will be directly used by the field. If num and userData are not correctly specified, the results are undefined (and probably undesirable). param num is the number of values that userData contains and must be a positive integer. param userData is an array allocated by malloc or realloc and can be deallocated by free (no constructor or destructor is called). userData must not be NULL. Its size must be at least num*sizeof(valueType).

Reimplemented from SoMFEnum.


The documentation for this class was generated from the following file:

Open Inventor Toolkit reference manual, generated on 15 Mar 2023
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/