SoRotor Class Reference
[Transforms]

Animated rotation node. More...

#include <Inventor/nodes/SoRotor.h>

Inheritance diagram for SoRotor:
SoRotation SoTransformation SoNode SoFieldContainer SoBase SoRefCounter SoTypedObject

List of all members.

Public Member Functions

virtual SoType getTypeId () const
 SoRotor ()

Static Public Member Functions

static SoType getClassTypeId ()

Public Attributes

SoSFFloat speed
SoSFBool on

Detailed Description

Animated rotation node.

The SoRotor class is derived from SoRotation, so it applies a rotation to the current transformation. Using engines connected to the realTime global field, the rotation value is animated over time, achieving a spinning effect. The period of the rotation can be adjusted by changing the speed field.

The current rotation at any time is available in the rotation field, inherited from SoRotation. This field can also be set to specify the axis of rotation.

Note that unless a non-zero rotation is specified for the rotation, the node will not know which axis to use. For example, to set a rotor to spin about the y-axis, use the following:

    SoRotor* rotor = new SoRotor();
    rotor->rotation.setValue( SbVec3f(0,1,0), 0.1f );

Any non-zero value can be used for the angle.

FILE FORMAT/DEFAULT

ACTION BEHAVIOR

SEE ALSO

SoPendulum, SoShuttle


Constructor & Destructor Documentation

SoRotor::SoRotor (  ) 

Creates a rotor node with default settings.


Member Function Documentation

static SoType SoRotor::getClassTypeId (  )  [static]

Returns the type identifier for this class.

Reimplemented from SoRotation.

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

Returns the type identifier for this specific instance.

Reimplemented from SoRotation.


Member Data Documentation

Allows applications to enable or disable the motion easily.

Defines the speed of the rotor, in revolutions per second.


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

Open Inventor Toolkit reference manual, generated on 12 Feb 2024
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/