1SoRotor(3IV)()                                                  SoRotor(3IV)()
2
3
4

NAME

6       SoRotor — animated rotation node
7

INHERITS FROM

9       SoBase  >  SoFieldContainer  > SoNode > SoTransformation > SoRotation >
10       SoRotor
11

SYNOPSIS

13       #include <Inventor/nodes/SoRotor.h>
14
15          Fields from class SoRotor:
16
17     SoSFFloat           speed
18     SoSFBool            on
19
20          Fields from class SoRotation:
21
22     SoSFRotation        rotation
23
24          Methods from class SoRotor:
25
26                         SoRotor()
27     static SoType       getClassTypeId()
28
29          Methods from class SoNode:
30
31     void                setOverride(SbBool state)
32     SbBool              isOverride() const
33     SoNode *            copy(SbBool copyConnections = FALSE) const
34     virtual SbBool      affectsState() const
35     static SoNode *     getByName(const SbName &name)
36     static int          getByName(const SbName &name, SoNodeList &list)
37
38          Methods from class SoFieldContainer:
39
40     void                setToDefaults()
41     SbBool              hasDefaultValues() const
42     SbBool              fieldsAreEqual(const SoFieldContainer *fc) const
43     void                copyFieldValues(const  SoFieldContainer  *fc,  SbBool
44                              copyConnections = FALSE)
45     SbBool              set(const char *fieldDataString)
46     void                get(SbString &fieldDataString)
47     virtual int         getFields(SoFieldList &resultList) const
48     virtual SoField *   getField(const SbName &fieldName) const
49     SbBool              getFieldName(const SoField *field, SbName &fieldName)
50                              const
51     SbBool              isNotifyEnabled() const
52     SbBool              enableNotify(SbBool flag)
53
54          Methods from class SoBase:
55
56     void                ref()
57     void                unref() const
58     void                unrefNoDelete() const
59     void                touch()
60     virtual SoType      getTypeId() const
61     SbBool              isOfType(SoType type) const
62     virtual void        setName(const SbName &name)
63     virtual SbName      getName() const
64
65

DESCRIPTION

67       The SoRotor class is derived from SoRotation, so it applies a  rotation
68       to  the current transformation. Using engines connected to the realTime
69       global field, the rotation value is animated  over  time,  achieving  a
70       spinning  effect.  The period of the rotation can be adjusted by chang‐
71       ing the speed field.
72
73       The current rotation at any time is available in  the  rotation  field,
74       inherited  from  SoRotation.  This field can also be set to specify the
75       axis of rotation.  Note that unless a non-zero  rotation  is  specified
76       for  the  rotation, the node will not know which axis to use. For exam‐
77       ple, to set a rotor to spin about the y-axis, use the following:
78          rotor->rotation.setValue(axis, 0.1);
79     where axis is a vector containing (0,1,0). Any non-zero angle can be used
80     in this code.
81

FIELDS

83     SoSFFloat           speed
84          Defines the speed of the rotor, in revolutions per second.
85
86     SoSFBool            on
87          Allows applications to enable or disable the motion easily.
88
89

METHODS

91                         SoRotor()
92          Creates a rotor node with default settings.
93
94     static SoType       getClassTypeId()
95          Returns type identifier for this class.
96
97

ACTION BEHAVIOR

99       SoGLRenderAction,  SoCallbackAction, SoGetBoundingBoxAction, SoRayPick‐
100       Action
101          Concatenates current rotation value with the current  transformation
102          matrix.
103
104     SoGetMatrixAction
105          Returns transformation matrix specified by the rotation.
106
107

FILE FORMAT/DEFAULTS

109       Rotor {
110          rotation  0 0 1  0
111          speed     1
112          on        TRUE
113     }
114

SEE ALSO

116       SoPendulum, SoShuttle
117
118
119
120
121                                                                SoRotor(3IV)()
Impressum