GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  SOSWITCH (3)

NAME

SoSwitch — group node that traverse one chosen child

CONTENTS

Inherits From
Synopsis
Description
Fields
Methods
Action Behavior
File Format/defaults
See Also

INHERITS FROM

SoBase > SoFieldContainer > SoNode > SoGroup > SoSwitch

SYNOPSIS

#include <Inventor/nodes/SoSwitch.h>

Fields from class SoSwitch:

    SoSFInt32    
                    
SoSFInt32            whichChild

Methods from class SoSwitch:

       
                    
                     SoSwitch()    
   
                    
                     SoSwitch(int nChildren)    
static SoType    
                    
static SoType        getClassTypeId()

Methods from class SoGroup:

    void    
                    
void                 addChild(SoNode *child)    
void    
                    
void                 insertChild(SoNode *child, int newChildIndex)    
SoNode *    
                    
SoNode *             getChild(int index) const    
int    
                    
int                  findChild(const SoNode *child) const    
int    
                    
int                  getNumChildren() const    
void    
                    
void                 removeChild(int index)    
void    
                    
void                 removeChild(SoNode *child)    
void    
                    
void                 removeAllChildren()    
void    
                    
void                 replaceChild(int index, SoNode *newChild)    
void    
                    
void                 replaceChild(SoNode *oldChild, SoNode *newChild)

Methods from class SoNode:

    void    
                    
void                 setOverride(SbBool state)    
SbBool    
                    
SbBool               isOverride() const    
SoNode *    
                    
SoNode *             copy(SbBool copyConnections = FALSE) const    
virtual SbBool    
                    
virtual SbBool       affectsState() const    
static SoNode *    
                    
static SoNode *      getByName(const SbName &name)    
static int    
                    
static int           getByName(const SbName &name, SoNodeList &list)

Methods from class SoFieldContainer:

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

Methods from class SoBase:

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

DESCRIPTION

This group node usually traverses only one or none of its children. It implements an operation similar to the switch statement in C. One can use this node to switch on and off the effects of some properties or to switch between different properties.

The whichChild field specifies the index of the child to traverse, where the first child has index 0.

A value of SO_SWITCH_NONE (-1, the default) means do not traverse any children. A value of SO_SWITCH_INHERIT (-2) allows the index to be inherited from a previously-encountered SoSwitch node or from certain other nodes (such as SoArray or SoMultipleCopy) that set the switch value. A value of SO_SWITCH_ALL (-3) traverses all children, making the switch behave exactly like a regular SoGroup.

FIELDS

    SoSFInt32    
                    
SoSFInt32            whichChild
Index of the child to traverse, or one of SO_SWITCH_NONE, SO_SWITCH_INHERIT, or SO_SWITCH_ALL.

METHODS

       
                    
                     SoSwitch()
Creates a switch node with default settings.

       
                    
                     SoSwitch(int nChildren)
Constructor that takes approximate number of children.

    static SoType    
                    
static SoType        getClassTypeId()
Returns type identifier for this class.

ACTION BEHAVIOR

SoGLRenderAction, SoCallbackAction, SoGetBoundingBoxAction, SoGetMatrixAction, SoHandleEventAction, SoRayPickAction
Traverses the chosen child or children.

SoSearchAction
If the action’s Searching-All flag is set, always traverses all children. Otherwise, traverses just the chosen child or children.

FILE FORMAT/DEFAULTS

Switch {



whichChild  -1


}

SEE ALSO

SoArray, SoLevelOfDetail, SoMultipleCopy, SoPathSwitch

Search for    or go to Top of page |  Section 3 |  Main Index


SOSWITCH(3IV) (-->)

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.