| VRS - The Virtual Rendering System |
| version 3.3 |
#include <vrs/sg/behaviornode.h>

Public Types | |
| enum | Hint { NoHint = 0x0000, Reset = 0x0001, Begin = 0x0002, End = 0x0004 } |
| enum | State { Inactive = 0x0000, Active = 0x0001 } |
| enum | InvalidationHint { RedrawNothing = 0x0000, RedrawWindow = 0x0001, RedrawWorld = 0x0002, RedrawAll = 0x0003 } |
Public Member Functions | |
| VRS_SERIALIZABLE_CLASS_ENUM (Hint) | |
| VRS_SERIALIZABLE_CLASS_ENUM (State) | |
| VRS_SERIALIZABLE_CLASS_ENUM (InvalidationHint) | |
| BehaviorNode (State state=BehaviorNode::Active) | |
| virtual TimeRequirement | timeRequirement () const |
| virtual void | activate (int hint=BehaviorNode::NoHint) |
| virtual void | deactivate (int hint=BehaviorNode::NoHint) |
| bool | isActive () const |
| virtual void | setNodeState (State state) |
| virtual State | getNodeState () const |
| virtual BehaviorNode::InvalidationHint | handle (Event *event)=0 |
| virtual SceneNodeVisitor::TraversalFlag | traverse (SceneNodeVisitor *visitor) |
| VRS_TYPEINFO (BehaviorNode, SharedObj) | |
| VRS_SERIALIZABLE_ABSTRACT_CLASS (BehaviorNode) | |
| VRS::BehaviorNode::BehaviorNode | ( | State | state = BehaviorNode::Active |
) |
By default, the state of the behavior node is set to "inactive".
| VRS::BehaviorNode::VRS_SERIALIZABLE_CLASS_ENUM | ( | Hint | ) |
| VRS::BehaviorNode::VRS_SERIALIZABLE_CLASS_ENUM | ( | State | ) |
| VRS::BehaviorNode::VRS_SERIALIZABLE_CLASS_ENUM | ( | InvalidationHint | ) |
| virtual TimeRequirement VRS::BehaviorNode::timeRequirement | ( | ) | const [virtual] |
A behavior node defines its time requirement. The default time requirement is set to "undefined".
Reimplemented in VRS::LeafBehavior, VRS::MonoBehavior, VRS::TimeCopy, VRS::TimeDuration, VRS::TimeGroup, and VRS::TimeModifier.
| virtual void VRS::BehaviorNode::activate | ( | int | hint = BehaviorNode::NoHint |
) | [virtual] |
Reimplemented in VRS::VideoController, VRS::BehaviorCallback, VRS::ColorLinearEffect, VRS::MonoBehavior, VRS::TimeCt< R, S, T >, and VRS::TimeGroup.
| virtual void VRS::BehaviorNode::deactivate | ( | int | hint = BehaviorNode::NoHint |
) | [virtual] |
Reimplemented in VRS::VideoController, VRS::BehaviorCallback, VRS::ColorLinearEffect, VRS::MonoBehavior, VRS::TimeCt< R, S, T >, and VRS::TimeGroup.
| bool VRS::BehaviorNode::isActive | ( | ) | const |
'activate' awakes a behavior node and its child nodes. 'deactivate' makes it fall asleep. Nodes may stop their activity when they become inactive. The current state can be inquired by 'getNodeState'. The `hint' is used to give extra information under which circumstances `activate' or `deactivate' were called.
Reimplemented in VRS::VideoController.
| virtual void VRS::BehaviorNode::setNodeState | ( | State | state | ) | [virtual] |
| virtual State VRS::BehaviorNode::getNodeState | ( | ) | const [virtual] |
A node can decide not to be evaluated, i.e., no time events and no canvas event are evaluated.
| virtual BehaviorNode::InvalidationHint VRS::BehaviorNode::handle | ( | Event * | event | ) | [pure virtual] |
'handle' receives and possibly propagates events. A behavior node returns an invalidation hint, indicating whether the associated canvas (if any) or the whole world (that is, all canvases) needs to be redrawn.
Implemented in VRS::AnimatedGifMaker, VRS::AVIMaker, VRS::VideoController, VRS::ApproachNavigation, VRS::BehaviorCallback, VRS::BehaviorGroup, VRS::ColorLinearEffect, VRS::EventFilter, VRS::EventSwitch, VRS::GameNavigation, VRS::Interaction, VRS::InteractionConcept, VRS::JumpNavigation, VRS::MonoBehavior, VRS::Navigation, VRS::PathNavigation, VRS::PhysicalNavigation, VRS::PickingCallback, VRS::PlaneNavigation, VRS::TimeCt< R, S, T >, VRS::TimeGroup, VRS::TimeModifier, VRS::TrackBall, and VRS::UfoPhysicalNavigation.
| virtual SceneNodeVisitor::TraversalFlag VRS::BehaviorNode::traverse | ( | SceneNodeVisitor * | visitor | ) | [virtual] |
A "visitor" can be sent through a behavior graph, e.g., for detecting certain behavior nodes etc.
Reimplemented in VRS::LeafBehavior, VRS::MonoBehavior, and VRS::PolyBehavior.
| VRS::BehaviorNode::VRS_TYPEINFO | ( | BehaviorNode | , | |
| SharedObj | ||||
| ) |
| VRS::BehaviorNode::VRS_SERIALIZABLE_ABSTRACT_CLASS | ( | BehaviorNode | ) |