Atoms Crowd  7.0.0
ArrowEmitterModule.h
1 #pragma once
2 #include <Atoms/BehaviourModule.h>
3 #include <AtomsCore/AtomsMath.h>
4 #include <map>
5 
6 
7 
8 
10 {
11 public:
12 
13  struct AgentData
14  {
16  AtomsCore::Matrix animMtxOnHeightField;
17  AtomsCore::Vector3 velocity;
18  size_t parentId;
19  double birth;
20  bool constrantActive;
21  bool onHeightField;
22  float param, u, v;
23  unsigned int faceId;
24  std::string hf;
25  std::string gf;
26  };
27 
29 
30  virtual ~ArrowEmitterModule();
31 
32  virtual void agentsCreated(const std::vector<Atoms::Agent*>& agents, Atoms::AgentGroup* agentGroup = nullptr);
33 
34  virtual void initFrame(const std::vector<Atoms::Agent*>& agents, Atoms::AgentGroup* agentGroup = nullptr);
35  virtual void endFrame(const std::vector<Atoms::Agent*>& agents, Atoms::AgentGroup* agentGroup = nullptr);
36 
37  static Atoms::BehaviourModule* creator(const std::string& parameter);
38 
39 private:
40 
41  std::map<int, AgentData> m_agentData;
42  unsigned int agentCounter;
43 };
Definition: ArrowEmitterModule.h:10
virtual void endFrame(const std::vector< Atoms::Agent * > &agents, Atoms::AgentGroup *agentGroup=nullptr)
End frame.
virtual void agentsCreated(const std::vector< Atoms::Agent * > &agents, Atoms::AgentGroup *agentGroup=nullptr)
Agents Created.
virtual void initFrame(const std::vector< Atoms::Agent * > &agents, Atoms::AgentGroup *agentGroup=nullptr)
Init frame.
Agent group.
Definition: AgentGroup.h:36
Behaviour module.
Definition: BehaviourModule.h:32
AtomsMath::Vector3 Vector3
Vector3 class.
Definition: AtomsMath.h:57
AtomsMath::Matrix Matrix
Matrix class.
Definition: AtomsMath.h:63
Definition: ArrowEmitterModule.h:14