15 #ifndef COLLISIONENTRY_H 16 #define COLLISIONENTRY_H 18 #include "pandabase.h" 20 #include "collisionTraverser.h" 21 #include "collisionSolid.h" 22 #include "collisionNode.h" 23 #include "collisionRecorder.h" 25 #include "transformState.h" 26 #include "typedWritableReferenceCount.h" 28 #include "pointerTo.h" 29 #include "pandaNode.h" 31 #include "clipPlaneAttrib.h" 49 CollisionEntry(
const CollisionEntry ©);
50 void operator = (
const CollisionEntry ©);
54 INLINE
bool has_into()
const;
59 INLINE
NodePath get_from_node_path()
const;
60 INLINE
NodePath get_into_node_path()
const;
62 INLINE
void set_t(PN_stdfloat t);
63 INLINE PN_stdfloat get_t()
const;
64 INLINE
bool collided()
const;
65 INLINE
void reset_collided();
67 INLINE
bool get_respect_prev_transform()
const;
69 INLINE
void set_surface_point(
const LPoint3 &point);
70 INLINE
void set_surface_normal(
const LVector3 &normal);
71 INLINE
void set_interior_point(
const LPoint3 &point);
73 INLINE
bool has_surface_point()
const;
74 INLINE
bool has_surface_normal()
const;
75 INLINE
bool has_interior_point()
const;
77 INLINE
void set_contact_pos(
const LPoint3 &pos);
78 INLINE
void set_contact_normal(
const LVector3 &normal);
80 INLINE
bool has_contact_pos()
const;
81 INLINE
bool has_contact_normal()
const;
93 bool get_all_contact_info(
const NodePath &space,
97 void output(ostream &out)
const;
98 void write(ostream &out,
int indent_level = 0)
const;
101 INLINE CPT(TransformState) get_wrt_space()
const;
102 INLINE CPT(TransformState) get_inv_wrt_space()
const;
103 INLINE CPT(TransformState) get_wrt_prev_space()
const;
105 INLINE
const LMatrix4 &get_wrt_mat()
const;
106 INLINE
const LMatrix4 &get_inv_wrt_mat()
const;
107 INLINE
const LMatrix4 &get_wrt_prev_mat()
const;
114 void check_clip_planes();
127 F_has_surface_point = 0x0001,
128 F_has_surface_normal = 0x0002,
129 F_has_interior_point = 0x0004,
130 F_respect_prev_transform = 0x0008,
131 F_checked_clip_planes = 0x0010,
132 F_has_contact_pos = 0x0020,
133 F_has_contact_normal = 0x0040,
149 static void init_type() {
150 TypedWritableReferenceCount::init_type();
151 register_type(_type_handle,
"CollisionEntry",
152 TypedWritableReferenceCount::get_class_type());
155 return get_class_type();
157 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
166 INLINE ostream &operator << (ostream &out,
const CollisionEntry &entry);
168 #include "collisionEntry.I" A basic node of the scene graph or data graph.
The abstract interface to a number of classes that decide what to do when a collision is detected...
A CollisionHandlerPusher that makes use of timing and spatial information from fluid collisions to im...
The abstract base class for all things that can collide with other things in the world, and all the things they can collide with (except geometry).
This is a three-component vector distance (as opposed to a three-component point, which represents a ...
This functions similarly to a LightAttrib.
This is a three-component point in space (as opposed to a three-component vector, which represents a ...
This is a 4-by-4 transform matrix.
Defines a single collision event.
A base class for things which need to inherit from both TypedWritable and from ReferenceCount.
A node in the scene graph that can hold any number of CollisionSolids.
This class manages the traversal through the scene graph to detect collisions.
TypeHandle is the identifier used to differentiate C++ class types.
NodePath is the fundamental system for disambiguating instances, and also provides a higher-level int...