OpenTracker

An Open Architecture for Reconfigurable Tracking based on XML | Contact

ot::TestSource Class Reference

#include <TestSource.h>

Inheritance diagram for ot::TestSource:

Inheritance graph
[legend]
Collaboration diagram for ot::TestSource:

Collaboration graph
[legend]
List of all members.

Public Member Functions

int isEventGenerator ()
void push (void)

Public Attributes

int frequency
int offset
double noise
Event event
Event perturbed

Protected Member Functions

 TestSource (int frequency_, int offset_)

Friends

class TestModule

Detailed Description

Definition at line 96 of file TestSource.h.


Constructor & Destructor Documentation

ot::TestSource::TestSource ( int  frequency_,
int  offset_ 
) [inline, protected]

simple constructor, sets members to initial values

Parameters:
frequency_ initial value for member frequency
offset_ initial value for member offset

Definition at line 116 of file TestSource.h.


Member Function Documentation

int ot::TestSource::isEventGenerator (  )  [inline, virtual]

tests for EventGenerator interface being present.

Is overriden to return 1 always.

Returns:
always 1

Reimplemented from ot::Node.

Definition at line 125 of file TestSource.h.

void ot::TestSource::push ( void   ) 

pushes event down the line.

Needed to access protected updateObservers method in EventGenerator. Note that the implementation of this method is in the file TestModule.cxx !

Definition at line 129 of file TestModule.cxx.

References event, ot::Event::getOrientation(), ot::Event::getPosition(), noise, ot::MathUtils::normalizeQuaternion(), perturbed, ot::Event::setAttribute(), ot::Event::setButton(), ot::Event::setConfidence(), ot::Event::timeStamp(), and ot::Node::updateObservers().


Friends And Related Function Documentation

friend class TestModule [friend]

Definition at line 136 of file TestSource.h.


Member Data Documentation

the original event

Definition at line 107 of file TestSource.h.

Referenced by ot::TestModule::createNode(), and push().

frequency of updates

Definition at line 101 of file TestSource.h.

use noise and noise level

Definition at line 105 of file TestSource.h.

Referenced by ot::TestModule::createNode(), and push().

offset of first update relative to main loop start

Definition at line 103 of file TestSource.h.

the perturbed event posted to the observers

Definition at line 109 of file TestSource.h.

Referenced by push().


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

copyright (c) 2006 Graz University of Technology