ot::ElasticFilterNode Class Reference
#include <ElasticFilterNode.h>
Inheritance diagram for ot::ElasticFilterNode:


Public Member Functions | |
| virtual int | isEventGenerator () |
| virtual void | onEventGenerated (Event &event, Node &generator) |
| void | push () |
Protected Member Functions | |
| ElasticFilterNode (float force_=0.02, float damp_=0.5, int frequency_=1, int offset_=0) | |
Protected Attributes | |
| bool | init |
| int | frequency |
| int | offset |
| float | damp |
| float | force |
| Event | currentEvent |
| Event | targetEvent |
| Event | vEvent |
Friends | |
| class | InterpolatorModule |
Detailed Description
Definition at line 77 of file ElasticFilterNode.h.
Constructor & Destructor Documentation
| ot::ElasticFilterNode::ElasticFilterNode | ( | float | force_ = 0.02, |
|
| float | damp_ = 0.5, |
|||
| int | frequency_ = 1, |
|||
| int | offset_ = 0 | |||
| ) | [protected] |
Member Function Documentation
| virtual int ot::ElasticFilterNode::isEventGenerator | ( | ) | [inline, virtual] |
tests for EventGenerator interface being present and returns 1, if present.
- Returns:
- always 1
Reimplemented from ot::Node.
Definition at line 102 of file ElasticFilterNode.h.
This method is called by any child node.
- Parameters:
-
event the event value passed generator the node generating the event
Reimplemented from ot::Node.
Definition at line 69 of file ElasticFilterNode.cxx.
References currentEvent, ot::Event::getButton(), ot::Event::getConfidence(), init, and targetEvent.
| void ot::ElasticFilterNode::push | ( | ) |
pushes event down the line.
Needed to access protected updateObservers method in EventGenerator
Definition at line 83 of file ElasticFilterNode.cxx.
References currentEvent, damp, force, ot::Event::getOrientation(), ot::Event::getPosition(), init, ot::MathUtils::slerp(), targetEvent, ot::Event::timeStamp(), ot::Node::updateObservers(), and vEvent.
Friends And Related Function Documentation
friend class InterpolatorModule [friend] |
Definition at line 118 of file ElasticFilterNode.h.
Member Data Documentation
Event ot::ElasticFilterNode::currentEvent [protected] |
float ot::ElasticFilterNode::damp [protected] |
the event that is posted to the EventObservers damping factor
Definition at line 87 of file ElasticFilterNode.h.
Referenced by ElasticFilterNode(), and push().
float ot::ElasticFilterNode::force [protected] |
the strength of the spring in our model
Definition at line 88 of file ElasticFilterNode.h.
Referenced by ElasticFilterNode(), and push().
int ot::ElasticFilterNode::frequency [protected] |
frequency of updates
Definition at line 83 of file ElasticFilterNode.h.
Referenced by ElasticFilterNode().
bool ot::ElasticFilterNode::init [protected] |
Definition at line 81 of file ElasticFilterNode.h.
Referenced by ElasticFilterNode(), onEventGenerated(), and push().
int ot::ElasticFilterNode::offset [protected] |
offset of first update relative to main loop start
Definition at line 85 of file ElasticFilterNode.h.
Referenced by ElasticFilterNode().
Event ot::ElasticFilterNode::targetEvent [protected] |
Event ot::ElasticFilterNode::vEvent [protected] |
The documentation for this class was generated from the following files: