Menge Plugin Examples
A Collection of Example Plugins for the Menge Framework
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
OpenSteerAgent.h
Go to the documentation of this file.
1 
9 #ifndef __OPEN_STEER_AGENT_H__
10 #define __OPEN_STEER_AGENT_H__
11 
12 #include "FDAgent.h"
13 
14 using namespace Menge;
15 
16 namespace OpenSteer {
20  class Agent : public Agents::FDAgent {
21  public:
25  Agent();
26 
30  ~Agent();
31 
35  void computeNewVelocity();
36 
40  float _tau;
41 
45  float _tauObst;
46 
47  protected:
48  // TODO: Get rid of the "forward" parameter -- that is just the orientation
49  // vector now.
60  bool steerToAvoidObstacles( const Vector2 & forward, Vector2 & avoidForce, const float maxForce );
61 
70  bool steerToAvoidNeighbors ( const Vector2 & forward, Vector2 & avoidForce );
71 
82  Vector2 calcBoidAccel( Vector2 & force, const Vector2 & forward );
83  };
84 } // namespace OpenSteer
85 
86 #endif // __OPEN_STEER_AGENT_H__
Contains the specification of the pedestrian model based on OpenSteer.
Definition: OpenSteerAgent.cpp:6
float _tauObst
The time horizon for predicting obstacle collisions.
Definition: OpenSteerAgent.h:45
The agent definition for the OpenSteer model.
Definition: OpenSteerAgent.h:20
float _tau
The time horizon for predicting agent collisions.
Definition: OpenSteerAgent.h:40