Robot Simulator of the Robotics Group for Self-Organization of Control  0.8.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TrackRobot Class Reference

This class provides tracking possibilies of a robot. More...

#include <trackrobots.h>

Collaboration diagram for TrackRobot:

Public Member Functions

 TrackRobot (TrackRobotConf conf=getDefaultConf())
 constructor for no tracking at all More...
 
 TrackRobot (bool trackPos, bool trackSpeed, bool trackOrientation, bool displayTrace, const char *scene="", int interval=1)
 Constructor that allows individial setting of tracking options. More...
 
 ~TrackRobot ()
 
bool isDisplayTrace () const
 returns whether tracing is activated More...
 
bool isTrackingSomething () const
 returns whether something is to be tracked More...
 
bool isEnabled ()
 

Static Public Member Functions

static TrackRobotConf getDefaultConf ()
 

Public Attributes

TrackRobotConf conf
 
bool enabledDuringVideo
 

Protected Member Functions

bool open (const Trackable *robot)
 
void track (const Trackable *robot, double time)
 
void close ()
 

Protected Attributes

FILE * file
 
long cnt
 

Friends

class Agent
 
class lpzrobots::OdeAgent
 
class lpzrobots::TraceDrawer
 

Detailed Description

This class provides tracking possibilies of a robot.

The position, speed, and orientation can be logged. This is used by the agent class,

See Also
Agent::setTrackOptions()

Constructor & Destructor Documentation

constructor for no tracking at all

TrackRobot ( bool  trackPos,
bool  trackSpeed,
bool  trackOrientation,
bool  displayTrace,
const char *  scene = "",
int  interval = 1 
)
inline

Constructor that allows individial setting of tracking options.

The tracked data is written into a file with the current date and time appended by a name given by scene.

Parameters
trackPosif true the trace (position vectors) of the robot are logged
trackSpeedif true the speed vectors (linear and angular) of the robot are logged
trackOrientationif true the orientation matrices of the robot are logged
displayTraceif true the trace of the robot should be displayed (used in ODE simulations)
scenename of the scene (is appended to log file name)
intervaltimesteps between consequent logging events (default 1)
~TrackRobot ( )
inline

Member Function Documentation

void close ( )
protected
static TrackRobotConf getDefaultConf ( )
inlinestatic
bool isDisplayTrace ( ) const
inline

returns whether tracing is activated

bool isEnabled ( )
inline
bool isTrackingSomething ( ) const
inline

returns whether something is to be tracked

bool open ( const Trackable robot)
protected
void track ( const Trackable robot,
double  time 
)
protected

Friends And Related Function Documentation

friend class Agent
friend
friend class lpzrobots::OdeAgent
friend
friend class lpzrobots::TraceDrawer
friend

Member Data Documentation

long cnt
protected
bool enabledDuringVideo
FILE* file
protected

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