Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKester Maddock <Christopher.Maddock.1@uni.massey.ac.nz>2005-03-25 13:33:39 +0300
committerKester Maddock <Christopher.Maddock.1@uni.massey.ac.nz>2005-03-25 13:33:39 +0300
commitc844aa265ad4eb50ad0e18661470fa6092052728 (patch)
treec4a778ab1227e4266022fd076e8a0cb709badd13 /source/gameengine/Physics/common/PHY_DynamicTypes.h
parent3dd17cec3bcaa3885e14630e6a71a8486e9b2697 (diff)
Big patches:
Erwin Coumans: Abstract the physics engine Charlie C: Joystick fixes Me: Moved the ray cast (shadows, mouse sensor & ray sensor)
Diffstat (limited to 'source/gameengine/Physics/common/PHY_DynamicTypes.h')
-rw-r--r--source/gameengine/Physics/common/PHY_DynamicTypes.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/source/gameengine/Physics/common/PHY_DynamicTypes.h b/source/gameengine/Physics/common/PHY_DynamicTypes.h
index 336e29e827a..f800a5494cb 100644
--- a/source/gameengine/Physics/common/PHY_DynamicTypes.h
+++ b/source/gameengine/Physics/common/PHY_DynamicTypes.h
@@ -42,6 +42,54 @@ typedef enum PHY_ScalarType {
PHY_FIXEDPOINT88
} PHY_ScalarType;
+class PHY_ResponseTable;
+
+class PHY_Shape;
+
+struct PHY__Vector3
+{
+ float m_vec[4];
+ operator const float* () const
+ {
+ return &m_vec[0];
+ }
+ operator float* ()
+ {
+ return &m_vec[0];
+ }
+};
+//typedef float PHY__Vector3[4];
+
+typedef enum
+{
+ PHY_FH_RESPONSE,
+ PHY_SENSOR_RESPONSE, /* Touch Sensors */
+ PHY_CAMERA_RESPONSE, /* Visibility Culling */
+ PHY_OBJECT_RESPONSE, /* Object Dynamic Geometry Response */
+ PHY_STATIC_RESPONSE, /* Static Geometry Response */
+
+ PHY_NUM_RESPONSE
+};
+
+ typedef struct PHY_CollData {
+ PHY__Vector3 m_point1; /* Point in object1 in world coordinates */
+ PHY__Vector3 m_point2; /* Point in object2 in world coordinates */
+ PHY__Vector3 m_normal; /* point2 - point1 */
+ } PHY_CollData;
+
+/* A response callback is called by SOLID for each pair of collding objects. 'client-data'
+ is a pointer to an arbitrary structure in the client application. The client objects are
+ pointers to structures in the client application associated with the coliding objects.
+ 'coll_data' is the collision data computed by SOLID.
+*/
+
+ typedef bool (*PHY_ResponseCallback)(void *client_data,
+ void *client_object1,
+ void *client_object2,
+ const PHY_CollData *coll_data);
+
+
+
/// PHY_PhysicsType enumerates all possible Physics Entities.
/// It is mainly used to create/add Physics Objects