Panda3D
collisionGeom.cxx
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file collisionGeom.cxx
10  * @author drose
11  * @date 2006-03-01
12  */
13 
14 #include "collisionGeom.h"
15 
16 PStatCollector CollisionGeom::_volume_pcollector("Collision Volumes:CollisionGeom");
17 PStatCollector CollisionGeom::_test_pcollector("Collision Tests:CollisionGeom");
18 TypeHandle CollisionGeom::_type_handle;
19 
20 /**
21  *
22  */
23 CollisionSolid *CollisionGeom::
24 make_copy() {
25  return new CollisionGeom(*this);
26 }
27 
28 /**
29  * Returns a PStatCollector that is used to count the number of bounding
30  * volume tests made against a solid of this type in a given frame.
31  */
34  return _volume_pcollector;
35 }
36 
37 /**
38  * Returns a PStatCollector that is used to count the number of intersection
39  * tests made against a solid of this type in a given frame.
40  */
43  return _test_pcollector;
44 }
45 
46 /**
47  *
48  */
49 void CollisionGeom::
50 output(std::ostream &out) const {
51  out << "cgeom";
52 }
virtual PStatCollector & get_volume_pcollector()
Returns a PStatCollector that is used to count the number of bounding volume tests made against a sol...
The abstract base class for all things that can collide with other things in the world,...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
A lightweight class that represents a single element that may be timed and/or counted via stats.
A special CollisionPolygon created just for the purpose of detecting collision against geometry.
Definition: collisionGeom.h:29
virtual PStatCollector & get_test_pcollector()
Returns a PStatCollector that is used to count the number of intersection tests made against a solid ...
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:81