Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/branches/physics/src/util/physics/physics_connection.h @ 4182

Last change on this file since 4182 was 4182, checked in by bensch, 19 years ago

orxonox/branches/physics: connection of Physical effects should work on ParticleSystems

File size: 1.2 KB
Line 
1/*!
2    \file physics_connection.h
3    \brief Definition of The Physical Connection Class.
4*/
5
6#ifndef _PHYSICS_CONNECTION_H
7#define _PHYSICS_CONNECTION_H
8
9//! An enumerator for different ConnectionTypes
10typedef enum PCON_Type { PCON_IPhysIPhys = 0,
11                         PCON_IPhysField = 1,
12                         PCON_ParticlesField = 2 };
13
14
15// Forward Declaration
16class Field;
17class IPhysics;
18class ParticleSystem;
19
20//! A class that Handles Physical Connection between subjects
21class PhysicsConnection {
22
23 public:
24  PhysicsConnection(IPhysics* partnerOne, IPhysics* partnerTwo);
25  PhysicsConnection(IPhysics* subject, Field* field);
26  PhysicsConnection(ParticleSystem* particleSystem, Field* field);
27
28  virtual ~PhysicsConnection();
29
30  void apply(void) const;
31
32 private:
33  PCON_Type type;                    //!< What kind of connection this is.
34 
35  IPhysics* subject;                 //!< The main Subject of this Connection.
36  IPhysics* partner2;                //!< The second partner of this Connection.
37 
38  ParticleSystem* particleSystem;    //!< A ParticleSystem in this Connection
39 
40  Field* field;                      //!< The field to connect either subject of ParticleSystem to.
41};
42
43#endif /* _PHYSICS_CONNECTION_H */
Note: See TracBrowser for help on using the repository browser.