Changeset 9869 in orxonox.OLD for trunk/src/lib/collision_detection
- Timestamp:
- Oct 3, 2006, 12:19:30 AM (18 years ago)
- Location:
- trunk/src/lib/collision_detection
- Files:
-
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/collision_detection/aabb.cc
r9406 r9869 21 21 22 22 23 23 ObjectListDefinition(AABB); 24 24 /** 25 25 * standard constructor … … 27 27 AABB::AABB () 28 28 { 29 this->setClassID(CL_OBB, "AABB");29 this->registerObject(this, AABB::_objectList); 30 30 this->halfLength[0] = this->halfLength[1] = this->halfLength[2] = 0.0f; 31 31 this->bCollided = false; -
trunk/src/lib/collision_detection/aabb.h
r8724 r9869 11 11 #include "bounding_volume.h" 12 12 13 template<class T> class tList;14 15 13 //! A class representing an extended bounding volume tree: an obb tree 16 14 class AABB : public BoundingVolume { 15 ObjectListDeclaration(AABB); 17 16 18 17 public: -
trunk/src/lib/collision_detection/aabb_tree_node.cc
r9494 r9869 32 32 #include "debug.h" 33 33 34 35 36 37 38 39 34 GLUquadricObj* AABBTreeNode_sphereObj = NULL; 40 35 41 36 ObjectListDefinition(AABBTreeNode); 42 37 /** 43 38 * standard constructor … … 48 43 : BVTreeNode() 49 44 { 50 this-> setClassID(CL_OBB_TREE_NODE, "AABBTreeNode");45 this->registerObject(this, AABBTreeNode::_objectList); 51 46 52 47 this->obbTree = &tree; -
trunk/src/lib/collision_detection/aabb_tree_node.h
r8724 r9869 21 21 class AABBTreeNode : public BVTreeNode 22 22 { 23 ObjectListDeclaration(AABBTreeNode); 23 24 24 25 -
trunk/src/lib/collision_detection/bounding_sphere.cc
r9406 r9869 20 20 21 21 22 22 ObjectListDefinition(BoundingSphere); 23 23 /** 24 24 * standard constructor … … 26 26 BoundingSphere::BoundingSphere () 27 27 { 28 this->setClassID(CL_BOUNDING_SPHERE, "BoundingSphere");28 this->registerObject(this, BoundingSphere::_objectList); 29 29 } 30 30 -
trunk/src/lib/collision_detection/bounding_sphere.h
r5039 r9869 1 /*! 1 /*! 2 2 * @file bounding_sphere.h 3 3 * Definition of a bounding sphere … … 14 14 //! A class representing an extended bounding volume tree: an sphere 15 15 class BoundingSphere : public BoundingVolume { 16 ObjectListDeclaration(BoundingSphere); 16 17 17 18 public: -
trunk/src/lib/collision_detection/bounding_volume.cc
r9406 r9869 20 20 21 21 22 22 ObjectListDefinition(BoundingVolume); 23 23 /** 24 24 * standard constructor … … 26 26 BoundingVolume::BoundingVolume () 27 27 { 28 this-> setClassID(CL_BOUNDING_VOLUME, "BoundingVolume");28 this->registerObject(this, BoundingVolume::_objectList); 29 29 this->modelInf = NULL; 30 30 this->triangleIndexes = NULL; -
trunk/src/lib/collision_detection/bounding_volume.h
r9008 r9869 17 17 //! An abstract class representing a bounding volume 18 18 class BoundingVolume : public BaseObject { 19 ObjectListDeclaration(BoundingVolume); 19 20 20 21 public: -
trunk/src/lib/collision_detection/bv_tree.cc
r9406 r9869 21 21 22 22 23 23 ObjectListDefinition(BVTree); 24 24 /** 25 25 * standard constructor … … 27 27 BVTree::BVTree () 28 28 { 29 this->setClassID(CL_BV_TREE, "BVTree");29 this->registerObject(this, BVTree::_objectList); 30 30 31 31 } -
trunk/src/lib/collision_detection/bv_tree.h
r7711 r9869 36 36 class BVTree : public BaseObject 37 37 { 38 ObjectListDeclaration(BVTree); 38 39 39 40 public: -
trunk/src/lib/collision_detection/bv_tree_node.cc
r9406 r9869 20 20 21 21 22 22 ObjectListDefinition(BVTreeNode); 23 23 /** 24 24 * standard constructor … … 26 26 BVTreeNode::BVTreeNode () 27 27 { 28 this->setClassID(CL_BV_TREE_NODE, "BVTreeNode");28 this->registerObject(this, BVTreeNode::_objectList); 29 29 30 30 } -
trunk/src/lib/collision_detection/bv_tree_node.h
r7732 r9869 24 24 //! A class that represents a bounding volume tree 25 25 class BVTreeNode : public BaseObject { 26 ObjectListDeclaration(BVTreeNode); 26 27 27 28 -
trunk/src/lib/collision_detection/cd_engine.cc
r9406 r9869 20 20 #include "debug.h" 21 21 22 #include "class_list.h"23 24 22 #include "model.h" 25 23 #include "world_entity.h" … … 36 34 37 35 38 36 ObjectListDefinition(CDEngine); 39 37 /** 40 * standard constructor38 * @brief standard constructor 41 39 */ 42 40 CDEngine::CDEngine () 43 41 { 44 this-> setClassID(CL_CD_ENGINE, "CDEngine");42 this->registerObject(this, CDEngine::_objectList); 45 43 46 44 this->bAbordOnFirstCollision = false; … … 103 101 void CDEngine::checkCollisionGround(std::list<WorldEntity*>& list1) 104 102 { 105 106 std::list<BaseObject*>::const_iterator bspIterator;107 103 std::list<WorldEntity*>::iterator entityIterator; 108 const std::list<BaseObject*>* bspList = ClassList::getList(CL_BSP_ENTITY);109 if( bspList == NULL)110 return;111 112 104 // for all bsp managers check all entities 113 for( bspIterator = bspList->begin(); bspIterator != bspList->end(); bspIterator++) { 105 for( ObjectList<BspEntity>::const_iterator bspIterator = BspEntity::objectList().begin(); 106 bspIterator != BspEntity::objectList().end(); 107 bspIterator++) { 114 108 for(entityIterator = list1.begin(); entityIterator != list1.end(); entityIterator++) 115 109 { -
trunk/src/lib/collision_detection/cd_engine.h
r8186 r9869 36 36 //! The class representing the collision detection system of orxonox 37 37 class CDEngine : public BaseObject { 38 ObjectListDeclaration(CDEngine); 38 39 39 40 friend class WorldEntity; -
trunk/src/lib/collision_detection/obb.cc
r9406 r9869 21 21 22 22 23 23 ObjectListDefinition(OBB); 24 24 /** 25 25 * standard constructor … … 27 27 OBB::OBB () 28 28 { 29 this->setClassID(CL_OBB, "OBB");29 this->registerObject(this, OBB::_objectList); 30 30 this->halfLength[0] = this->halfLength[1] = this->halfLength[2] = 0.0f; 31 31 this->bCollided = false; -
trunk/src/lib/collision_detection/obb.h
r7711 r9869 15 15 //! A class representing an extended bounding volume tree: an obb tree 16 16 class OBB : public BoundingVolume { 17 ObjectListDeclaration(OBB); 17 18 18 19 public: -
trunk/src/lib/collision_detection/obb_tree.cc
r9406 r9869 27 27 28 28 29 29 ObjectListDefinition(OBBTree); 30 30 /** 31 31 * standard constructor … … 51 51 void OBBTree::init() 52 52 { 53 this-> setClassID(CL_OBB_TREE, "OBBTree");53 this->registerObject(this, OBBTree::_objectList); 54 54 this->rootNode = NULL; 55 55 this->id = 0; -
trunk/src/lib/collision_detection/obb_tree.h
r9235 r9869 20 20 class OBBTree : public BVTree 21 21 { 22 ObjectListDeclaration(OBBTree); 22 23 23 24 public: -
trunk/src/lib/collision_detection/obb_tree_node.cc
r9406 r9869 38 38 GLUquadricObj* OBBTreeNode_sphereObj = NULL; 39 39 40 40 ObjectListDefinition(OBBTreeNode); 41 41 /** 42 42 * standard constructor … … 47 47 : BVTreeNode() 48 48 { 49 this-> setClassID(CL_OBB_TREE_NODE, "OBBTreeNode");49 this->registerObject(this, OBBTreeNode::_objectList); 50 50 51 51 this->obbTree = &tree; … … 284 284 285 285 /** 286 * calculate the eigenvectors for the object oriented box286 * @brief calculate the eigenvectors for the object oriented box 287 287 * @param box: reference to the box 288 288 * @param modelInf: the model info structure of the model … … 361 361 362 362 /** 363 * this separates an ob-box in the middle363 * @brief this separates an ob-box in the middle 364 364 * @param box: the box to separate 365 365 * -
trunk/src/lib/collision_detection/obb_tree_node.h
r9235 r9869 17 17 class PNode; 18 18 19 20 19 //! A class that represents a bounding volume tree 21 20 class OBBTreeNode : public BVTreeNode 22 21 { 23 24 22 ObjectListDeclaration(OBBTreeNode); 25 23 public: 26 24 OBBTreeNode(const OBBTree& tree, OBBTreeNode* prev, int depth);
Note: See TracChangeset
for help on using the changeset viewer.