AnimatLab  2
Test
OdorSensor.h
Go to the documentation of this file.
1 
7 #pragma once
8 
9 namespace AnimatSim
10 {
11  namespace Environment
12  {
13  namespace Bodies
14  {
24  class ANIMAT_PORT OdorSensor : public Sensor
25  {
26  protected:
29 
32 
34  std::string m_strOdorTypeID;
35 
36  virtual void SetOdorTypePointer(std::string strID);
37 
38  public:
39  OdorSensor();
40  virtual ~OdorSensor();
41 
42  static OdorSensor *CastToDerived(AnimatBase *lpBase) {return static_cast<OdorSensor*>(lpBase);}
43 
44  virtual void OdorTypeID(std::string strID);
45  virtual std::string OdorTypeID();
46 
47  virtual void ResetSimulation();
48  virtual bool SetData(const std::string &strDataType, const std::string &strValue, bool bThrowError = true);
49  virtual void QueryProperties(CStdPtrArray<TypeProperty> &aryProperties);
50  virtual float *GetDataPointer(const std::string &strDataType);
51  virtual void StepSimulation();
52  virtual void Load(CStdXml &oXml);
53  };
54 
55  } //Bodies
56  } // Environment
57 } //AnimatSim
Root namespace for the base simulation library for AnimatLab.
OdorType * m_lpOdorType
Pointer to the type odor to detect.
Definition: OdorSensor.h:31
Odor type that can be emitted from a RigidBody and sensed by an OdorSensor.
Definition: OdorType.h:27
std::string m_strOdorTypeID
Identifier for the odor type.
Definition: OdorSensor.h:34
Animat base class.
Definition: AnimatBase.h:36
float m_fltOdorValue
The odor concentration value.
Definition: OdorSensor.h:28