logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

SoArray — group node that creates a regular IxJxK array of copies of its children

Action Behavior

SoGLRenderAction,SoCallbackAction,SoGetBoundingBoxAction,SoRayPickAction
          Traverses  all  children  for  each  array  element,  saving and restoring state before and after each
          traversal.

     SoSearchAction
          Traverses all children once, setting the inherited switch value to SO_SWITCH_ALL first.

Description

       This group node traverses its children, in order, several times, creating a regular 3D array of copies of
       them.  The  number  of  copies in each of the three directions is specified by fields, as are the vectors
       used to separate the copies in each of the three dimensions.

       For example, an SoArray node can be used to create a 2x3x4 array of copies of  its  children,  where  the
       separation  vectors  between  adjacent  copies in the three array dimensions are (1,2,3), (-4,-5,-6), and
       (7,8,9), respectively. The base point of the array can be set to one of several values, as  described  in
       the origin field.

       Copies  are  traversed  so that the first dimension cycles most quickly, followed by the second, and then
       the third. This order is important because SoArray sets the current switch value to N  before  traversing
       the children for the Nth time (for use with inherited switch values - see SoSwitch).

Fields

SoSFShortnumElements1SoSFShortnumElements2SoSFShortnumElements3
          Number of elements in each of the three array dimensions.

     SoSFVec3fseparation1SoSFVec3fseparation2SoSFVec3fseparation3
          Separation vector in each of the three array dimensions.

     SoSFEnumorigin
          Defines the base point from which copies are distributed.

File Format/Defaults

Array{numElements11numElements21numElements31separation1100separation2010separation3001originFIRST}

Inherits From

       SoBase > SoFieldContainer > SoNode > SoGroup > SoArray

Methods

SoArray()
          Creates an array node with default settings.

     staticSoTypegetClassTypeId()
          Returns type identifier for this class.

Name

       SoArray — group node that creates a regular IxJxK array of copies of its children

See Also

SoMultipleCopy,SoSwitchSoArray(3IV)()

Synopsis

#include<Inventor/nodes/SoArray.h>enumOrigin{SoArray::FIRST      First  copy  is  rendered  at  the  current  local  origin;  all  other copies are
                                   distributed relative to it
          SoArray::CENTER     Copies are distributed relative to the center of the array
          SoArray::LAST       Last copy  is  rendered  at  the  current  local  origin;  all  other  copies  are
                                   distributed relative to it
     }

          Fields from class SoArray:

     SoSFShortnumElements1SoSFShortnumElements2SoSFShortnumElements3SoSFVec3fseparation1SoSFVec3fseparation2SoSFVec3fseparation3SoSFEnumorigin

          Methods from class SoArray:

                         SoArray()staticSoTypegetClassTypeId()

          Methods from class SoGroup:

     voidaddChild(SoNode*child)voidinsertChild(SoNode*child,intnewChildIndex)SoNode*getChild(intindex)constintfindChild(constSoNode*child)constintgetNumChildren()constvoidremoveChild(intindex)voidremoveChild(SoNode*child)voidremoveAllChildren()voidreplaceChild(intindex,SoNode*newChild)voidreplaceChild(SoNode*oldChild,SoNode*newChild)

          Methods from class SoNode:

     voidsetOverride(SbBoolstate)SbBoolisOverride()constSoNode*copy(SbBoolcopyConnections=FALSE)constvirtualSbBoolaffectsState()conststaticSoNode*getByName(constSbName&name)staticintgetByName(constSbName&name,SoNodeList&list)

          Methods from class SoFieldContainer:

     voidsetToDefaults()SbBoolhasDefaultValues()constSbBoolfieldsAreEqual(constSoFieldContainer*fc)constvoidcopyFieldValues(constSoFieldContainer*fc,SbBoolcopyConnections=FALSE)SbBoolset(constchar*fieldDataString)voidget(SbString&fieldDataString)virtualintgetFields(SoFieldList&resultList)constvirtualSoField*getField(constSbName&fieldName)constSbBoolgetFieldName(constSoField*field,SbName&fieldName)constSbBoolisNotifyEnabled()constSbBoolenableNotify(SbBoolflag)

          Methods from class SoBase:

     voidref()voidunref()constvoidunrefNoDelete()constvoidtouch()virtualSoTypegetTypeId()constSbBoolisOfType(SoTypetype)constvirtualvoidsetName(constSbName&name)virtualSbNamegetName()const

See Also