Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4520 in orxonox.OLD


Ignore:
Timestamp:
Jun 6, 2005, 11:06:16 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: implemented bv, collision, and added a global cd defs file

Location:
orxonox/trunk/src/util/collision_detection
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/util/collision_detection/bounding_volume.h

    r4511 r4520  
    1010#include "base_object.h"
    1111
     12class sVect3D;
     13class Vector;
    1214
    1315//! An abstract class representing a bounding volume
     
    1820  virtual ~BoundingVolume();
    1921
     22  inline const Vector* getCenter() const { return this->center; }
     23  inline const Vector* getAxis () const { return this->axis; }
     24  inline const sVect3D* getHalfLength() const { return this->halfLength; }
     25
     26  sVect3D* getVertices() const;
     27  void mergeWith(const BoundingVolume& bv);
    2028
    2129 private:
     30  Vector*    center;                     //!< Center point of box
     31  Vector*    axis;                       //!< Axes of oriented box [x,y,z]
     32  sVect3D*   halfLength;                 //!< Half lengths of the box
     33
    2234
    2335};
  • orxonox/trunk/src/util/collision_detection/collision.h

    r4511 r4520  
    99
    1010#include "base_object.h"
     11#include "vector.h"
    1112
    1213// FORWARD DEFINITION
    13 
    14 
     14class WorldEntity;
     15class sVec3D;
     16class BoundingVolume;
    1517
    1618//! A class representing a simple collision
     
    2123  virtual ~Collision();
    2224
    23 
    24  private:
    25 
     25 public:
     26  Vector            pointOfImpact;              //!< point of impact, approximated via bounding volumes
     27  WorldEntity*      body;                       //!< the collision body
     28  BoundingVolume*   boundingVolume;             //!< reference to the bounding volume that fired the collision
    2629};
    2730
Note: See TracChangeset for help on using the changeset viewer.