H3D API
2.4.1
|
The TimeHandler field updates once per scene-graph loop to monitor the current time and updates the fields in the owner X3DTimeDependentNode if any state changes has to be made. More...
#include <H3D/X3DTimeDependentNode.h>
Public Member Functions | |
virtual void | activate (H3DTime time) |
Activate the time node. Start generating time based events. | |
virtual void | deactivate (H3DTime time) |
Deactivate the time node. More... | |
![]() | |
virtual void | propagateEvent (Field::Event e) |
Receive an event from another field. More... | |
![]() | |
virtual string | getTypeName () |
Returns a string name for this field type e.g. SFInt32. | |
![]() | |
SField () | |
Constructor. | |
SField (const H3DDouble &_value) | |
Constructor. | |
virtual int | setValueFromVoidPtr (const void *data, unsigned int len, int id=0) |
Set the value of the field given a pointer to where the value of the field is. More... | |
virtual int | getValueAsVoidPtr (void *data, unsigned int len, int id=0) |
Get the value of the data copied into a memory buffer. More... | |
virtual unsigned int | valueTypeSize () |
Returns the size in bytes of the value type the sfield encapsulates. | |
virtual void | setValue (const H3DDouble &v, int id=0) |
Set the value of the field. | |
virtual const H3DDouble & | getValue (int id=0) |
Get the value of the field. | |
virtual void | setValueFromString (const string &s) |
Set the value of the field given a string. More... | |
virtual string | getValueAsString (const string &=" ") |
Get the value of the field as a string. | |
![]() | |
virtual | ~SFieldClass () |
Virtual destructor. | |
virtual int | setValueFromVoidPtr (void *data, unsigned int size, int id=0) |
Protected Member Functions | |
virtual void | update () |
This function handles all logic for state changes and field updates to the X3DTimeDependentNode. More... | |
![]() | |
void | checkFieldType (Field *f, int index) |
Function for checking that a field is of a correct type given type specification according to the TypedField template arguments. More... | |
void | checkTemplateArguments () |
Function for checking that a field given TypedField type specification is valid. More... | |
![]() | |
void | checkFieldType (Field *f, int index) |
Function for checking that a field is of a correct type given type specification according to the TypedField template arguments. More... | |
void | checkTemplateArguments () |
Function for checking that a field given TypedField type specification is valid. More... | |
Additional Inherited Members | |
![]() | |
typedef H3DDouble | value_type |
The type of the value member. | |
![]() | |
static string | classTypeName () |
Returns a string name for this field type e.g. SFInt32. | |
![]() | |
H3DDouble | value |
The encapsulated value. | |
The TimeHandler field updates once per scene-graph loop to monitor the current time and updates the fields in the owner X3DTimeDependentNode if any state changes has to be made.
It sets fields in the X3DTimeDependentNode accordingly.
routes_in[0] Scene.time
|
virtual |
Deactivate the time node.
No events will be generated after a call to this function.
References H3D::X3DTimeDependentNode::isActive, and H3D::X3DTimeDependentNode::onStop().
Referenced by H3D::X3DSoundSourceNode::TimeHandler::update().
|
protectedvirtual |
This function handles all logic for state changes and field updates to the X3DTimeDependentNode.
It will be called once per scene-graph loop to set the fields in the time node depending on the current time.
Reimplemented from H3D::SField< H3DDouble >.
Reimplemented in H3D::X3DSoundSourceNode::TimeHandler, and H3D::TimeSensor::TimeHandler.
References H3D::X3DTimeDependentNode::elapsedTime, H3D::X3D::Convert::getValue(), H3D::X3DTimeDependentNode::isActive, H3D::X3DTimeDependentNode::isPaused, H3D::X3DTimeDependentNode::onPause(), H3D::X3DTimeDependentNode::onResume(), H3D::X3DTimeDependentNode::pauseTime, H3D::X3DTimeDependentNode::resumeTime, H3D::X3DTimeDependentNode::startTime, and H3D::X3DTimeDependentNode::stopTime.
Referenced by H3D::TimeSensor::TimeHandler::update(), and H3D::X3DSoundSourceNode::TimeHandler::update().