iso::flock::CircularBehavior Class Reference

cause Agent to move withing a ring More...

#include <iso_flock_circular_behavior.h>

Inherits iso::flock::Behavior.

Inheritance diagram for iso::flock::CircularBehavior:

Inheritance graph
[legend]
Collaboration diagram for iso::flock::CircularBehavior:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 CircularBehavior (const base::String &pInputParameterString, const base::String &pOutputParameterString)
 create behavior
 CircularBehavior (Agent *pAgent, const base::String &pBehaviorName, const base::String &pInputParameterString, const base::String &pOutputParameterString) throw (FlockException)
 create behavior
 ~CircularBehavior ()
 destructor
virtual Behavior * create (const base::String &pBehaviorName, Agent *pAgent) const throw (FlockException)
 create copy of behavior
virtual Behavior * create (const base::String &pInputParameterString, const base::String &pOutputParameterString) const
 create copy of behavior
void act ()
 perform behavior

Protected Attributes

Parameter * mPosition
Parameter * mForce
 position parameter (input)
Parameter * mInnerRadiusPar
 force parameter (output)
Parameter * mOuterRadiusPar
 inner radius parameter (internal)
Parameter * mRadialAmountPar
 outer radius parameter (internal)
math::Vector3< real > mCenterVec
 radial amount parameter (internal)
math::Vector3< real > mNormZVec
 vector pointing from agent position towards origin
math::Vector3< real > mNormTangentVec
 noralized vector pointing in positive z-direction

Detailed Description

cause Agent to move withing a ring

to move withing a ring

The Behavior causes Agent to move withing a ring
Input Parameter:
type: position dim: nD neighbors: ignore

Output Parameter:
type: force dim: nD write: add

Internal Parameter:
name: xxx_innerRadius dim: 1D defaultValue: 2.0
name: xxx_outerRadius dim: 1D defaultValue: 3.0
name: xxx_radialAmount dim: 1D defaultValue: 0.1
name: xxx_active dim: 1D defaultValue: 1.0

Created by Daniel Bisig, Tasuo Unemi, Koichiro Mori, John Flury on 11/16/07.


Constructor & Destructor Documentation

CircularBehavior::CircularBehavior ( const base::String &  pInputParameterString,
const base::String &  pOutputParameterString 
)

create behavior

Parameters:
pInputParameterString input parameter string (parameters are space separated)
pOutputParameterString output paramaters are space separated)

CircularBehavior::CircularBehavior ( Agent *  pAgent,
const base::String &  pBehaviorName,
const base::String &  pInputParameterString,
const base::String &  pOutputParameterString 
) throw (FlockException)

create behavior

Parameters:
pAgent agent this behavior belongs to
pBehaviorName name of behavior
pInputParameterString input parameter string (parameters are space separated)
pOutputParameterString output paramaters are space separated)
Exceptions:
FlockException wrong number of type of parameters

CircularBehavior::~CircularBehavior (  ) 

destructor


Member Function Documentation

Behavior * CircularBehavior::create ( const base::String &  pBehaviorName,
Agent *  pAgent 
) const throw (FlockException) [virtual]

create copy of behavior

Parameters:
pAgent agent this behavior belongs to
pBehaviorName name of behavior
Returns:
new behavior
Exceptions:
FlockException wrong number of type of parameters

Implements iso::flock::Behavior.

Behavior * CircularBehavior::create ( const base::String &  pInputParameterString,
const base::String &  pOutputParameterString 
) const [virtual]

create copy of behavior

Parameters:
pInputParameterString input parameter string
pOutputParameterString output parameter string
Returns:
new behavior

Implements iso::flock::Behavior.

void CircularBehavior::act (  )  [virtual]

perform behavior

Implements iso::flock::Behavior.


Member Data Documentation

Parameter* iso::flock::CircularBehavior::mPosition [protected]

Parameter* iso::flock::CircularBehavior::mForce [protected]

position parameter (input)

Parameter* iso::flock::CircularBehavior::mInnerRadiusPar [protected]

force parameter (output)

Parameter* iso::flock::CircularBehavior::mOuterRadiusPar [protected]

inner radius parameter (internal)

Parameter* iso::flock::CircularBehavior::mRadialAmountPar [protected]

outer radius parameter (internal)

math::Vector3<real> iso::flock::CircularBehavior::mCenterVec [protected]

radial amount parameter (internal)

math::Vector3<real> iso::flock::CircularBehavior::mNormZVec [protected]

vector pointing from agent position towards origin

math::Vector3<real> iso::flock::CircularBehavior::mNormTangentVec [protected]

noralized vector pointing in positive z-direction


The documentation for this class was generated from the following files:
Generated on Fri Feb 25 15:28:03 2011 for iso_flock by  doxygen 1.5.1