OpenTracker

An Open Architecture for Reconfigurable Tracking based on XML | Contact

ot::CommonNodeFactory Class Reference

#include <CommonNodeFactory.h>

Inheritance diagram for ot::CommonNodeFactory:

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

Collaboration graph
[legend]
List of all members.

Public Member Functions

 CommonNodeFactory ()
virtual ~CommonNodeFactory ()
virtual NodecreateNode (const std::string &name, StringTable &attributes)

Static Protected Member Functions

static int parseVector (const std::string &line, float *val)
static int parseRotation (const std::string &line, const std::string &type, float *val)

Protected Attributes

std::vector< std::string > nodePorts

Detailed Description

Definition at line 75 of file CommonNodeFactory.h.


Constructor & Destructor Documentation

ot::CommonNodeFactory::CommonNodeFactory (  ) 

constructor method.

Initalizes the wrapperNodes array.

Definition at line 85 of file CommonNodeFactory.cxx.

References nodePorts.

ot::CommonNodeFactory::~CommonNodeFactory (  )  [virtual]

destructor

Definition at line 98 of file CommonNodeFactory.cxx.

References nodePorts.


Member Function Documentation

int ot::CommonNodeFactory::parseRotation ( const std::string &  line,
const std::string &  type,
float *  val 
) [static, protected]

parses a string for a rotation, where the type is defined by a second string, returns int value indicating an error.

If an error occurs, the val values are not changed.

Parameters:
line string to parse
type string defining type of rotation (quaternion|matrix|axisangle|euler)
val pointer to four floats, rotation will be stored in quaternion format
Returns:
0 if ok, other value if error occured

Definition at line 118 of file CommonNodeFactory.cxx.

References ot::MathUtils::axisAngleToQuaternion(), ot::MathUtils::determinant(), ot::MathUtils::eulerToQuaternion(), ot::MathUtils::matrixToQuaternion(), and ot::MathUtils::normalizeQuaternion().

Referenced by createNode().

int ot::CommonNodeFactory::parseVector ( const std::string &  line,
float *  val 
) [static, protected]

parses a string for a three component vector, returns int value indicating an error.

If an error occurs, the val values are not changed.

Parameters:
line string to parse
val pointer to three floats
Returns:
0 if ok, other value if error occured

Definition at line 103 of file CommonNodeFactory.cxx.

Referenced by createNode().


Member Data Documentation

std::vector<std::string> ot::CommonNodeFactory::nodePorts [protected]

stores names of known NodePorts, to make instantiation more generic

Definition at line 81 of file CommonNodeFactory.h.

Referenced by CommonNodeFactory(), createNode(), and ~CommonNodeFactory().


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

copyright (c) 2006 Graz University of Technology