Browse Source

Merge branch 'master' into cmake

Sam Edwards 8 years ago
parent
commit
fa483357f3
59 changed files with 531 additions and 66 deletions
  1. 17 17
      direct/src/fsm/FourState.py
  2. 23 23
      direct/src/fsm/FourStateAI.py
  3. 12 0
      panda/src/bullet/bulletAllHitsRayResult.h
  4. 9 0
      panda/src/bullet/bulletBodyNode.cxx
  5. 25 2
      panda/src/bullet/bulletBodyNode.h
  6. 3 0
      panda/src/bullet/bulletBoxShape.h
  7. 3 0
      panda/src/bullet/bulletCapsuleShape.h
  8. 1 2
      panda/src/bullet/bulletCharacterControllerNode.cxx
  9. 9 2
      panda/src/bullet/bulletCharacterControllerNode.h
  10. 9 0
      panda/src/bullet/bulletClosestHitRayResult.h
  11. 7 0
      panda/src/bullet/bulletClosestHitSweepResult.h
  12. 3 0
      panda/src/bullet/bulletConeShape.h
  13. 4 0
      panda/src/bullet/bulletConeTwistConstraint.h
  14. 1 1
      panda/src/bullet/bulletConstraint.I
  15. 10 3
      panda/src/bullet/bulletConstraint.h
  16. 8 0
      panda/src/bullet/bulletContactCallbackData.h
  17. 3 3
      panda/src/bullet/bulletContactCallbacks.h
  18. 9 0
      panda/src/bullet/bulletContactResult.h
  19. 2 0
      panda/src/bullet/bulletConvexPointCloudShape.h
  20. 4 0
      panda/src/bullet/bulletCylinderShape.h
  21. 36 0
      panda/src/bullet/bulletDebugNode.I
  22. 9 0
      panda/src/bullet/bulletDebugNode.h
  23. 4 0
      panda/src/bullet/bulletFilterCallbackData.h
  24. 4 0
      panda/src/bullet/bulletGenericConstraint.h
  25. 2 0
      panda/src/bullet/bulletGhostNode.h
  26. 3 0
      panda/src/bullet/bulletHelper.h
  27. 7 0
      panda/src/bullet/bulletHingeConstraint.h
  28. 24 0
      panda/src/bullet/bulletManifoldPoint.h
  29. 6 0
      panda/src/bullet/bulletMinkowskiSumShape.h
  30. 4 0
      panda/src/bullet/bulletMultiSphereShape.h
  31. 6 0
      panda/src/bullet/bulletPersistentManifold.h
  32. 3 0
      panda/src/bullet/bulletPlaneShape.h
  33. 17 0
      panda/src/bullet/bulletRigidBodyNode.h
  34. 7 0
      panda/src/bullet/bulletRotationalLimitMotor.h
  35. 11 1
      panda/src/bullet/bulletShape.h
  36. 15 0
      panda/src/bullet/bulletSliderConstraint.h
  37. 2 2
      panda/src/bullet/bulletSoftBodyConfig.I
  38. 28 2
      panda/src/bullet/bulletSoftBodyConfig.h
  39. 6 5
      panda/src/bullet/bulletSoftBodyMaterial.h
  40. 15 0
      panda/src/bullet/bulletSoftBodyNode.h
  41. 2 0
      panda/src/bullet/bulletSoftBodyShape.h
  42. 6 0
      panda/src/bullet/bulletSoftBodyWorldInfo.h
  43. 2 0
      panda/src/bullet/bulletSphereShape.h
  44. 3 0
      panda/src/bullet/bulletSphericalConstraint.h
  45. 2 0
      panda/src/bullet/bulletTickCallbackData.h
  46. 6 2
      panda/src/bullet/bulletTranslationalLimitMotor.h
  47. 3 0
      panda/src/bullet/bulletTriangleMesh.h
  48. 3 0
      panda/src/bullet/bulletTriangleMeshShape.h
  49. 13 0
      panda/src/bullet/bulletVehicle.h
  50. 35 0
      panda/src/bullet/bulletWheel.h
  51. 9 0
      panda/src/bullet/bulletWorld.I
  52. 12 0
      panda/src/bullet/bulletWorld.h
  53. 6 0
      panda/src/text/config_text.cxx
  54. 1 0
      panda/src/text/config_text.h
  55. 26 0
      panda/src/text/dynamicTextFont.cxx
  56. 1 0
      panda/src/text/dynamicTextFont.h
  57. 18 1
      panda/src/text/textAssembler.cxx
  58. 10 0
      panda/src/text/textFont.cxx
  59. 2 0
      panda/src/text/textFont.h

+ 17 - 17
direct/src/fsm/FourState.py

@@ -90,7 +90,8 @@ class FourState:
         off (and so is state 2 which is oposite of 4 and therefore
         off (and so is state 2 which is oposite of 4 and therefore
         oposite of 'on').
         oposite of 'on').
         """
         """
-        assert self.debugPrint("FourState(names=%s)"%(names))
+        self.stateIndex = 0
+        assert self.__debugPrint("FourState(names=%s)"%(names))
         self.track = None
         self.track = None
         self.stateTime = 0.0
         self.stateTime = 0.0
         self.names = names
         self.names = names
@@ -120,7 +121,6 @@ class FourState:
                            self.exitState4,
                            self.exitState4,
                            [names[1]]),
                            [names[1]]),
             }
             }
-        self.stateIndex = 0
         self.fsm = ClassicFSM.ClassicFSM('FourState',
         self.fsm = ClassicFSM.ClassicFSM('FourState',
                            list(self.states.values()),
                            list(self.states.values()),
                            # Initial State
                            # Initial State
@@ -131,7 +131,7 @@ class FourState:
         self.fsm.enterInitialState()
         self.fsm.enterInitialState()
 
 
     def setTrack(self, track):
     def setTrack(self, track):
-        assert self.debugPrint("setTrack(track=%s)"%(track,))
+        assert self.__debugPrint("setTrack(track=%s)"%(track,))
         if self.track is not None:
         if self.track is not None:
             self.track.pause()
             self.track.pause()
             self.track = None
             self.track = None
@@ -147,27 +147,27 @@ class FourState:
     # If the client wants the state changed it needs to
     # If the client wants the state changed it needs to
     # send a request to the AI.
     # send a request to the AI.
     #def setIsOn(self, isOn):
     #def setIsOn(self, isOn):
-    #    assert self.debugPrint("setIsOn(isOn=%s)"%(isOn,))
+    #    assert self.__debugPrint("setIsOn(isOn=%s)"%(isOn,))
     #    pass
     #    pass
 
 
     def isOn(self):
     def isOn(self):
-        assert self.debugPrint("isOn() returning %s (stateIndex=%s)"%(self.stateIndex==4, self.stateIndex))
+        assert self.__debugPrint("isOn() returning %s (stateIndex=%s)"%(self.stateIndex==4, self.stateIndex))
         return self.stateIndex==4
         return self.stateIndex==4
 
 
     def changedOnState(self, isOn):
     def changedOnState(self, isOn):
         """
         """
         Allow derived classes to overide this.
         Allow derived classes to overide this.
         """
         """
-        assert self.debugPrint("changedOnState(isOn=%s)"%(isOn,))
+        assert self.__debugPrint("changedOnState(isOn=%s)"%(isOn,))
 
 
     ##### state 0 #####
     ##### state 0 #####
 
 
     def enterState0(self):
     def enterState0(self):
-        assert self.debugPrint("enter0()")
+        assert self.__debugPrint("enter0()")
         self.enterStateN(0)
         self.enterStateN(0)
 
 
     def exitState0(self):
     def exitState0(self):
-        assert self.debugPrint("exit0()")
+        assert self.__debugPrint("exit0()")
         # It's important for FourStates to broadcast their state
         # It's important for FourStates to broadcast their state
         # when they are generated on the client. Before I put this in,
         # when they are generated on the client. Before I put this in,
         # if a door was generated and went directly to an 'open' state,
         # if a door was generated and went directly to an 'open' state,
@@ -177,43 +177,43 @@ class FourState:
     ##### state 1 #####
     ##### state 1 #####
 
 
     def enterState1(self):
     def enterState1(self):
-        assert self.debugPrint("enterState1()")
+        assert self.__debugPrint("enterState1()")
         self.enterStateN(1)
         self.enterStateN(1)
 
 
     def exitState1(self):
     def exitState1(self):
-        assert self.debugPrint("exitState1()")
+        assert self.__debugPrint("exitState1()")
 
 
     ##### state 2 #####
     ##### state 2 #####
 
 
     def enterState2(self):
     def enterState2(self):
-        assert self.debugPrint("enterState2()")
+        assert self.__debugPrint("enterState2()")
         self.enterStateN(2)
         self.enterStateN(2)
 
 
     def exitState2(self):
     def exitState2(self):
-        assert self.debugPrint("exitState2()")
+        assert self.__debugPrint("exitState2()")
 
 
     ##### state 3 #####
     ##### state 3 #####
 
 
     def enterState3(self):
     def enterState3(self):
-        assert self.debugPrint("enterState3()")
+        assert self.__debugPrint("enterState3()")
         self.enterStateN(3)
         self.enterStateN(3)
 
 
     def exitState3(self):
     def exitState3(self):
-        assert self.debugPrint("exitState3()")
+        assert self.__debugPrint("exitState3()")
 
 
     ##### state 4 #####
     ##### state 4 #####
 
 
     def enterState4(self):
     def enterState4(self):
-        assert self.debugPrint("enterState4()")
+        assert self.__debugPrint("enterState4()")
         self.enterStateN(4)
         self.enterStateN(4)
         self.changedOnState(1)
         self.changedOnState(1)
 
 
     def exitState4(self):
     def exitState4(self):
-        assert self.debugPrint("exitState4()")
+        assert self.__debugPrint("exitState4()")
         self.changedOnState(0)
         self.changedOnState(0)
 
 
     if __debug__:
     if __debug__:
-        def debugPrint(self, message):
+        def __debugPrint(self, message):
             """for debugging"""
             """for debugging"""
             return self.notify.debug("%d (%d) %s"%(
             return self.notify.debug("%d (%d) %s"%(
                     id(self), self.stateIndex==4, message))
                     id(self), self.stateIndex==4, message))

+ 23 - 23
direct/src/fsm/FourStateAI.py

@@ -93,11 +93,11 @@ class FourStateAI:
         off (and so is state 2 which is oposite of state 4 and therefore
         off (and so is state 2 which is oposite of state 4 and therefore
         oposite of 'on').
         oposite of 'on').
         """
         """
-        assert self.debugPrint(
+        self.stateIndex = 0
+        assert self.__debugPrint(
                 "FourStateAI(names=%s, durations=%s)"
                 "FourStateAI(names=%s, durations=%s)"
                 %(names, durations))
                 %(names, durations))
         self.doLaterTask = None
         self.doLaterTask = None
-        self.stateIndex = 0
         assert len(names) == 5
         assert len(names) == 5
         assert len(names) == len(durations)
         assert len(names) == len(durations)
         self.names = names
         self.names = names
@@ -137,7 +137,7 @@ class FourStateAI:
         self.fsm.enterInitialState()
         self.fsm.enterInitialState()
 
 
     def delete(self):
     def delete(self):
-        assert self.debugPrint("delete()")
+        assert self.__debugPrint("delete()")
         if self.doLaterTask is not None:
         if self.doLaterTask is not None:
             self.doLaterTask.remove()
             self.doLaterTask.remove()
             del self.doLaterTask
             del self.doLaterTask
@@ -145,15 +145,15 @@ class FourStateAI:
         del self.fsm
         del self.fsm
 
 
     def getState(self):
     def getState(self):
-        assert self.debugPrint("getState() returning %s"%(self.stateIndex,))
+        assert self.__debugPrint("getState() returning %s"%(self.stateIndex,))
         return [self.stateIndex]
         return [self.stateIndex]
 
 
     def sendState(self):
     def sendState(self):
-        assert self.debugPrint("sendState()")
+        assert self.__debugPrint("sendState()")
         self.sendUpdate('setState', self.getState())
         self.sendUpdate('setState', self.getState())
 
 
     def setIsOn(self, isOn):
     def setIsOn(self, isOn):
-        assert self.debugPrint("setIsOn(isOn=%s)"%(isOn,))
+        assert self.__debugPrint("setIsOn(isOn=%s)"%(isOn,))
         if isOn:
         if isOn:
             if self.stateIndex != 4:
             if self.stateIndex != 4:
                 # ...if it's not On; request turning on:
                 # ...if it's not On; request turning on:
@@ -170,7 +170,7 @@ class FourStateAI:
         #    self.fsm.request(self.states[nextState])
         #    self.fsm.request(self.states[nextState])
 
 
     def isOn(self):
     def isOn(self):
-        assert self.debugPrint("isOn() returning %s (stateIndex=%s)"%(self.stateIndex==4, self.stateIndex))
+        assert self.__debugPrint("isOn() returning %s (stateIndex=%s)"%(self.stateIndex==4, self.stateIndex))
         return self.stateIndex==4
         return self.stateIndex==4
 
 
     def changedOnState(self, isOn):
     def changedOnState(self, isOn):
@@ -179,12 +179,12 @@ class FourStateAI:
         The self.isOn value has toggled.  Call getIsOn() to
         The self.isOn value has toggled.  Call getIsOn() to
         get the current state.
         get the current state.
         """
         """
-        assert self.debugPrint("changedOnState(isOn=%s)"%(isOn,))
+        assert self.__debugPrint("changedOnState(isOn=%s)"%(isOn,))
 
 
     ##### states #####
     ##### states #####
 
 
     def switchToNextStateTask(self, task):
     def switchToNextStateTask(self, task):
-        assert self.debugPrint("switchToNextStateTask()")
+        assert self.__debugPrint("switchToNextStateTask()")
         self.fsm.request(self.states[self.nextStateIndex])
         self.fsm.request(self.states[self.nextStateIndex])
         return Task.done
         return Task.done
 
 
@@ -193,11 +193,11 @@ class FourStateAI:
         This function is intentionaly simple so that derived classes
         This function is intentionaly simple so that derived classes
         may easily alter the network message.
         may easily alter the network message.
         """
         """
-        assert self.debugPrint("distributeStateChange()")
+        assert self.__debugPrint("distributeStateChange()")
         self.sendState()
         self.sendState()
 
 
     def enterStateN(self, stateIndex, nextStateIndex):
     def enterStateN(self, stateIndex, nextStateIndex):
-        assert self.debugPrint(
+        assert self.__debugPrint(
             "enterStateN(stateIndex=%s, nextStateIndex=%s)"%
             "enterStateN(stateIndex=%s, nextStateIndex=%s)"%
             (stateIndex, nextStateIndex))
             (stateIndex, nextStateIndex))
         self.stateIndex = stateIndex
         self.stateIndex = stateIndex
@@ -211,7 +211,7 @@ class FourStateAI:
                 "enterStateN-timer-%s"%id(self))
                 "enterStateN-timer-%s"%id(self))
 
 
     def exitStateN(self):
     def exitStateN(self):
-        assert self.debugPrint("exitStateN()")
+        assert self.__debugPrint("exitStateN()")
         if self.doLaterTask:
         if self.doLaterTask:
             taskMgr.remove(self.doLaterTask)
             taskMgr.remove(self.doLaterTask)
             self.doLaterTask=None
             self.doLaterTask=None
@@ -219,56 +219,56 @@ class FourStateAI:
     ##### state 0 #####
     ##### state 0 #####
 
 
     def enterState0(self):
     def enterState0(self):
-        assert self.debugPrint("enter0()")
+        assert self.__debugPrint("enter0()")
         self.enterStateN(0, 0)
         self.enterStateN(0, 0)
 
 
     def exitState0(self):
     def exitState0(self):
-        assert self.debugPrint("exit0()")
+        assert self.__debugPrint("exit0()")
 
 
     ##### state 1 #####
     ##### state 1 #####
 
 
     def enterState1(self):
     def enterState1(self):
-        #assert self.debugPrint("enterState1()")
+        #assert self.__debugPrint("enterState1()")
         self.enterStateN(1, 2)
         self.enterStateN(1, 2)
 
 
     def exitState1(self):
     def exitState1(self):
-        assert self.debugPrint("exitState1()")
+        assert self.__debugPrint("exitState1()")
         self.exitStateN()
         self.exitStateN()
 
 
     ##### state 2 #####
     ##### state 2 #####
 
 
     def enterState2(self):
     def enterState2(self):
-        #assert self.debugPrint("enterState2()")
+        #assert self.__debugPrint("enterState2()")
         self.enterStateN(2, 3)
         self.enterStateN(2, 3)
 
 
     def exitState2(self):
     def exitState2(self):
-        assert self.debugPrint("exitState2()")
+        assert self.__debugPrint("exitState2()")
         self.exitStateN()
         self.exitStateN()
 
 
     ##### state 3 #####
     ##### state 3 #####
 
 
     def enterState3(self):
     def enterState3(self):
-        #assert self.debugPrint("enterState3()")
+        #assert self.__debugPrint("enterState3()")
         self.enterStateN(3, 4)
         self.enterStateN(3, 4)
 
 
     def exitState3(self):
     def exitState3(self):
-        assert self.debugPrint("exitState3()")
+        assert self.__debugPrint("exitState3()")
         self.exitStateN()
         self.exitStateN()
 
 
     ##### state 4 #####
     ##### state 4 #####
 
 
     def enterState4(self):
     def enterState4(self):
-        assert self.debugPrint("enterState4()")
+        assert self.__debugPrint("enterState4()")
         self.enterStateN(4, 1)
         self.enterStateN(4, 1)
         self.changedOnState(1)
         self.changedOnState(1)
 
 
     def exitState4(self):
     def exitState4(self):
-        assert self.debugPrint("exitState4()")
+        assert self.__debugPrint("exitState4()")
         self.exitStateN()
         self.exitStateN()
         self.changedOnState(0)
         self.changedOnState(0)
 
 
     if __debug__:
     if __debug__:
-        def debugPrint(self, message):
+        def __debugPrint(self, message):
             """for debugging"""
             """for debugging"""
             return self.notify.debug("%d (%d) %s"%(
             return self.notify.debug("%d (%d) %s"%(
                     id(self), self.stateIndex==4, message))
                     id(self), self.stateIndex==4, message))

+ 12 - 0
panda/src/bullet/bulletAllHitsRayResult.h

@@ -39,6 +39,13 @@ PUBLISHED:
   int get_shape_part() const;
   int get_shape_part() const;
   int get_triangle_index() const;
   int get_triangle_index() const;
 
 
+  MAKE_PROPERTY(node, get_node);
+  MAKE_PROPERTY(hit_pos, get_hit_pos);
+  MAKE_PROPERTY(hit_normal, get_hit_normal);
+  MAKE_PROPERTY(hit_fraction, get_hit_fraction);
+  MAKE_PROPERTY(shape_part, get_shape_part);
+  MAKE_PROPERTY(triangle_index, get_triangle_index);
+
 private:
 private:
   const btCollisionObject *_object;
   const btCollisionObject *_object;
   btVector3 _normal;
   btVector3 _normal;
@@ -69,6 +76,11 @@ PUBLISHED:
   const BulletRayHit get_hit(int idx) const;
   const BulletRayHit get_hit(int idx) const;
   MAKE_SEQ(get_hits, get_num_hits, get_hit);
   MAKE_SEQ(get_hits, get_num_hits, get_hit);
 
 
+  MAKE_PROPERTY(from_pos, get_from_pos);
+  MAKE_PROPERTY(to_pos, get_to_pos);
+  MAKE_PROPERTY(closest_hit_fraction, get_closest_hit_fraction);
+  MAKE_SEQ_PROPERTY(hits, get_num_hits, get_hit);
+
 public:
 public:
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
   virtual btScalar addSingleResult(btCollisionWorld::LocalRayResult& rayResult, bool normalInWorldSpace);
   virtual btScalar addSingleResult(btCollisionWorld::LocalRayResult& rayResult, bool normalInWorldSpace);

+ 9 - 0
panda/src/bullet/bulletBodyNode.cxx

@@ -442,6 +442,15 @@ set_active(bool active, bool force) {
   }
   }
 }
 }
 
 
+/**
+ *
+ */
+void BulletBodyNode::
+force_active(bool active) {
+
+  set_active(active, true);
+}
+
 /**
 /**
  * If true, this object will be deactivated after a certain amount of time has
  * If true, this object will be deactivated after a certain amount of time has
  * passed without movement.  If false, the object will always remain active.
  * passed without movement.  If false, the object will always remain active.

+ 25 - 2
panda/src/bullet/bulletBodyNode.h

@@ -56,7 +56,7 @@ PUBLISHED:
   // Static and kinematic
   // Static and kinematic
   INLINE bool is_static() const;
   INLINE bool is_static() const;
   INLINE bool is_kinematic() const;
   INLINE bool is_kinematic() const;
-
+  
   INLINE void set_static(bool value);
   INLINE void set_static(bool value);
   INLINE void set_kinematic(bool value);
   INLINE void set_kinematic(bool value);
 
 
@@ -79,6 +79,7 @@ PUBLISHED:
   // Deactivation
   // Deactivation
   bool is_active() const;
   bool is_active() const;
   void set_active(bool active, bool force=false);
   void set_active(bool active, bool force=false);
+  void force_active(bool active);
 
 
   void set_deactivation_time(PN_stdfloat dt);
   void set_deactivation_time(PN_stdfloat dt);
   PN_stdfloat get_deactivation_time() const;
   PN_stdfloat get_deactivation_time() const;
@@ -86,7 +87,7 @@ PUBLISHED:
   void set_deactivation_enabled(bool enabled);
   void set_deactivation_enabled(bool enabled);
   bool is_deactivation_enabled() const;
   bool is_deactivation_enabled() const;
 
 
-  // Debug Visualistion
+  // Debug Visualisation
   INLINE void set_debug_enabled(const bool enabled);
   INLINE void set_debug_enabled(const bool enabled);
   INLINE bool is_debug_enabled() const;
   INLINE bool is_debug_enabled() const;
 
 
@@ -100,6 +101,7 @@ PUBLISHED:
 #if BT_BULLET_VERSION >= 281
 #if BT_BULLET_VERSION >= 281
   INLINE PN_stdfloat get_rolling_friction() const;
   INLINE PN_stdfloat get_rolling_friction() const;
   INLINE void set_rolling_friction(PN_stdfloat friction);
   INLINE void set_rolling_friction(PN_stdfloat friction);
+  MAKE_PROPERTY(rolling_friction, get_rolling_friction, set_rolling_friction);
 #endif
 #endif
 
 
   INLINE bool has_anisotropic_friction() const;
   INLINE bool has_anisotropic_friction() const;
@@ -115,6 +117,27 @@ PUBLISHED:
   // Special
   // Special
   void set_transform_dirty();
   void set_transform_dirty();
 
 
+  MAKE_SEQ_PROPERTY(shapes, get_num_shapes, get_shape);
+  MAKE_SEQ_PROPERTY(shape_pos, get_num_shapes, get_shape_pos);
+  MAKE_SEQ_PROPERTY(shape_mat, get_num_shapes, get_shape_mat);
+  MAKE_SEQ_PROPERTY(shape_transform, get_num_shapes, get_shape_transform);
+  MAKE_PROPERTY(shape_bounds, get_shape_bounds);
+  MAKE_PROPERTY(static, is_static, set_static);
+  MAKE_PROPERTY(kinematic, is_kinematic, set_kinematic);
+  MAKE_PROPERTY(collision_notification, notifies_collisions, notify_collisions);
+  MAKE_PROPERTY(collision_response, get_collision_response, set_collision_response);
+  MAKE_PROPERTY(contact_response, has_contact_response);
+  MAKE_PROPERTY(contact_processing_threshold, get_contact_processing_threshold, set_contact_processing_threshold);
+  MAKE_PROPERTY(active, is_active, force_active);
+  MAKE_PROPERTY(deactivation_time, get_deactivation_time, set_deactivation_time);
+  MAKE_PROPERTY(deactivation_enabled, is_deactivation_enabled, set_deactivation_enabled);
+  MAKE_PROPERTY(debug_enabled, is_debug_enabled, set_debug_enabled);
+  MAKE_PROPERTY(restitution, get_restitution, set_restitution);
+  MAKE_PROPERTY(friction, get_friction, set_friction);
+  MAKE_PROPERTY(anisotropic_friction, get_anisotropic_friction, set_anisotropic_friction);
+  MAKE_PROPERTY(ccd_swept_sphere_radius, get_ccd_swept_sphere_radius, set_ccd_swept_sphere_radius);
+  MAKE_PROPERTY(ccd_motion_threshold, get_ccd_motion_threshold, set_ccd_motion_threshold);
+
 public:
 public:
   virtual btCollisionObject *get_object() const = 0;
   virtual btCollisionObject *get_object() const = 0;
 
 

+ 3 - 0
panda/src/bullet/bulletBoxShape.h

@@ -42,6 +42,9 @@ PUBLISHED:
 
 
   static BulletBoxShape *make_from_solid(const CollisionBox *solid);
   static BulletBoxShape *make_from_solid(const CollisionBox *solid);
 
 
+  MAKE_PROPERTY(half_extents_with_margin, get_half_extents_with_margin);
+  MAKE_PROPERTY(half_extents_without_margin, get_half_extents_without_margin);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 3 - 0
panda/src/bullet/bulletCapsuleShape.h

@@ -34,6 +34,9 @@ PUBLISHED:
   INLINE PN_stdfloat get_radius() const;
   INLINE PN_stdfloat get_radius() const;
   INLINE PN_stdfloat get_half_height() const;
   INLINE PN_stdfloat get_half_height() const;
 
 
+  MAKE_PROPERTY(radius, get_radius);
+  MAKE_PROPERTY(half_height, get_half_height);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 1 - 2
panda/src/bullet/bulletCharacterControllerNode.cxx

@@ -296,7 +296,6 @@ set_gravity(PN_stdfloat gravity) {
 #endif
 #endif
 }
 }
 
 
-
 /**
 /**
  *
  *
  */
  */
@@ -304,4 +303,4 @@ void BulletCharacterControllerNode::
 set_use_ghost_sweep_test(bool value) {
 set_use_ghost_sweep_test(bool value) {
 
 
   return _character->setUseGhostSweepTest(value);
   return _character->setUseGhostSweepTest(value);
-}
+}

+ 9 - 2
panda/src/bullet/bulletCharacterControllerNode.h

@@ -39,20 +39,27 @@ PUBLISHED:
 
 
   BulletShape *get_shape() const;
   BulletShape *get_shape() const;
 
 
+  void set_gravity(PN_stdfloat gravity);
   PN_stdfloat get_gravity() const;
   PN_stdfloat get_gravity() const;
-  PN_stdfloat get_max_slope() const;
 
 
   void set_fall_speed(PN_stdfloat fall_speed);
   void set_fall_speed(PN_stdfloat fall_speed);
   void set_jump_speed(PN_stdfloat jump_speed);
   void set_jump_speed(PN_stdfloat jump_speed);
   void set_max_jump_height(PN_stdfloat max_jump_height);
   void set_max_jump_height(PN_stdfloat max_jump_height);
+  
   void set_max_slope(PN_stdfloat max_slope);
   void set_max_slope(PN_stdfloat max_slope);
-  void set_gravity(PN_stdfloat gravity);
+  PN_stdfloat get_max_slope() const;
+
   void set_use_ghost_sweep_test(bool value);
   void set_use_ghost_sweep_test(bool value);
 
 
   bool is_on_ground() const;
   bool is_on_ground() const;
   bool can_jump() const;
   bool can_jump() const;
   void do_jump();
   void do_jump();
 
 
+  MAKE_PROPERTY(shape, get_shape);
+  MAKE_PROPERTY(gravity, get_gravity, set_gravity);
+  MAKE_PROPERTY(max_slope, get_max_slope, set_max_slope);
+  MAKE_PROPERTY(on_ground, is_on_ground);
+
 public:
 public:
   INLINE virtual btPairCachingGhostObject *get_ghost() const;
   INLINE virtual btPairCachingGhostObject *get_ghost() const;
   INLINE virtual btCharacterControllerInterface *get_character() const;
   INLINE virtual btCharacterControllerInterface *get_character() const;

+ 9 - 0
panda/src/bullet/bulletClosestHitRayResult.h

@@ -44,6 +44,15 @@ PUBLISHED:
   int get_shape_part() const;
   int get_shape_part() const;
   int get_triangle_index() const;
   int get_triangle_index() const;
 
 
+  MAKE_PROPERTY(from_pos, get_from_pos);
+  MAKE_PROPERTY(to_pos, get_to_pos);
+  MAKE_PROPERTY(node, get_node);
+  MAKE_PROPERTY(hit_pos, get_hit_pos);
+  MAKE_PROPERTY(hit_normal, get_hit_normal);
+  MAKE_PROPERTY(hit_fraction, get_hit_fraction);
+  MAKE_PROPERTY(shape_part, get_shape_part);
+  MAKE_PROPERTY(triangle_index, get_triangle_index);
+
 public:
 public:
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
   virtual btScalar addSingleResult(btCollisionWorld::LocalRayResult& rayResult, bool normalInWorldSpace);
   virtual btScalar addSingleResult(btCollisionWorld::LocalRayResult& rayResult, bool normalInWorldSpace);

+ 7 - 0
panda/src/bullet/bulletClosestHitSweepResult.h

@@ -41,6 +41,13 @@ PUBLISHED:
   LVector3 get_hit_normal() const;
   LVector3 get_hit_normal() const;
   PN_stdfloat get_hit_fraction() const;
   PN_stdfloat get_hit_fraction() const;
 
 
+  MAKE_PROPERTY(from_pos, get_from_pos);
+  MAKE_PROPERTY(to_pos, get_to_pos);
+  MAKE_PROPERTY(node, get_node);
+  MAKE_PROPERTY(hit_pos, get_hit_pos);
+  MAKE_PROPERTY(hit_normal, get_hit_normal);
+  MAKE_PROPERTY(hit_fraction, get_hit_fraction);
+
 public:
 public:
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
   virtual bool needsCollision(btBroadphaseProxy* proxy0) const;
 
 

+ 3 - 0
panda/src/bullet/bulletConeShape.h

@@ -34,6 +34,9 @@ PUBLISHED:
   INLINE PN_stdfloat get_radius() const;
   INLINE PN_stdfloat get_radius() const;
   INLINE PN_stdfloat get_height() const;
   INLINE PN_stdfloat get_height() const;
 
 
+  MAKE_PROPERTY(radius, get_radius);
+  MAKE_PROPERTY(height, get_height);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 4 - 0
panda/src/bullet/bulletConeTwistConstraint.h

@@ -56,6 +56,10 @@ PUBLISHED:
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_b() const;
   INLINE CPT(TransformState) get_frame_b() const;
 
 
+  MAKE_PROPERTY(fix_threshold, get_fix_threshold, set_fix_threshold);
+  MAKE_PROPERTY(frame_a, get_frame_a);
+  MAKE_PROPERTY(frame_b, get_frame_b);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const;
   virtual btTypedConstraint *ptr() const;
 
 

+ 1 - 1
panda/src/bullet/bulletConstraint.I

@@ -34,7 +34,7 @@ set_breaking_threshold(PN_stdfloat threshold) {
  * Returns the applied impluse limit for breaking the constraint.
  * Returns the applied impluse limit for breaking the constraint.
  */
  */
 INLINE PN_stdfloat BulletConstraint::
 INLINE PN_stdfloat BulletConstraint::
-set_breaking_threshold() const {
+get_breaking_threshold() const {
 
 
   return (PN_stdfloat)ptr()->getBreakingImpulseThreshold();
   return (PN_stdfloat)ptr()->getBreakingImpulseThreshold();
 }
 }

+ 10 - 3
panda/src/bullet/bulletConstraint.h

@@ -34,13 +34,13 @@ PUBLISHED:
   BulletRigidBodyNode *get_rigid_body_b();
   BulletRigidBodyNode *get_rigid_body_b();
 
 
   void enable_feedback(bool value);
   void enable_feedback(bool value);
-  void set_debug_draw_size(PN_stdfloat size);
 
 
-  PN_stdfloat get_applied_impulse() const;
+  void set_debug_draw_size(PN_stdfloat size);
   PN_stdfloat get_debug_draw_size();
   PN_stdfloat get_debug_draw_size();
 
 
+  PN_stdfloat get_applied_impulse() const;
   INLINE void set_breaking_threshold(PN_stdfloat threshold);
   INLINE void set_breaking_threshold(PN_stdfloat threshold);
-  INLINE PN_stdfloat set_breaking_threshold() const;
+  INLINE PN_stdfloat get_breaking_threshold() const;
   INLINE void set_enabled(bool enabled);
   INLINE void set_enabled(bool enabled);
   INLINE bool is_enabled() const;
   INLINE bool is_enabled() const;
 
 
@@ -54,6 +54,13 @@ PUBLISHED:
   void set_param(ConstraintParam num, PN_stdfloat value, int axis=-1);
   void set_param(ConstraintParam num, PN_stdfloat value, int axis=-1);
   PN_stdfloat get_param(ConstraintParam num, int axis=-1);
   PN_stdfloat get_param(ConstraintParam num, int axis=-1);
 
 
+  MAKE_PROPERTY(rigid_body_a, get_rigid_body_a);
+  MAKE_PROPERTY(rigid_body_b, get_rigid_body_b);
+  MAKE_PROPERTY(debug_draw_size, get_debug_draw_size, set_debug_draw_size);
+  MAKE_PROPERTY(applied_impulse, get_applied_impulse);
+  MAKE_PROPERTY(breaking_threshold, get_breaking_threshold, set_breaking_threshold);
+  MAKE_PROPERTY(enabled, is_enabled, set_enabled);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const = 0;
   virtual btTypedConstraint *ptr() const = 0;
 
 

+ 8 - 0
panda/src/bullet/bulletContactCallbackData.h

@@ -41,6 +41,14 @@ PUBLISHED:
   INLINE int get_index0() const;
   INLINE int get_index0() const;
   INLINE int get_index1() const;
   INLINE int get_index1() const;
 
 
+  MAKE_PROPERTY(manifold, get_manifold);
+  MAKE_PROPERTY(node0, get_node0);
+  MAKE_PROPERTY(node1, get_node1);
+  MAKE_PROPERTY(part_id0, get_part_id0);
+  MAKE_PROPERTY(part_id1, get_part_id1);
+  MAKE_PROPERTY(index0, get_index0);
+  MAKE_PROPERTY(index1, get_index1);
+
 private:
 private:
   BulletManifoldPoint &_mp;
   BulletManifoldPoint &_mp;
   PandaNode *_node0;
   PandaNode *_node0;

+ 3 - 3
panda/src/bullet/bulletContactCallbacks.h

@@ -26,7 +26,7 @@
 #include "eventParameter.h"
 #include "eventParameter.h"
 #include "pandaNode.h"
 #include "pandaNode.h"
 
 
-struct UserPersitentData {
+struct UserPersistentData {
   PT(PandaNode) node0;
   PT(PandaNode) node0;
   PT(PandaNode) node1;
   PT(PandaNode) node1;
 };
 };
@@ -64,7 +64,7 @@ contact_added_callback(btManifoldPoint &cp,
     bullet_cat.debug() << "contact added: " << cp.m_userPersistentData << endl;
     bullet_cat.debug() << "contact added: " << cp.m_userPersistentData << endl;
 
 
     // Gather persistent data
     // Gather persistent data
-    UserPersitentData *data = new UserPersitentData();
+    UserPersistentData *data = new UserPersistentData();
     data->node0 = node0;
     data->node0 = node0;
     data->node1 = node1;
     data->node1 = node1;
 
 
@@ -126,7 +126,7 @@ contact_destroyed_callback(void *userPersistentData) {
 
 
   bullet_cat.debug() << "contact removed: " << userPersistentData << endl;
   bullet_cat.debug() << "contact removed: " << userPersistentData << endl;
 
 
-  UserPersitentData *data = (UserPersitentData *)userPersistentData;
+  UserPersistentData *data = (UserPersistentData *)userPersistentData;
 
 
   // Send event
   // Send event
   if (bullet_enable_contact_events) {
   if (bullet_enable_contact_events) {

+ 9 - 0
panda/src/bullet/bulletContactResult.h

@@ -39,6 +39,14 @@ PUBLISHED:
   INLINE int get_part_id0() const;
   INLINE int get_part_id0() const;
   INLINE int get_part_id1() const;
   INLINE int get_part_id1() const;
 
 
+  MAKE_PROPERTY(manifold_point, get_manifold_point);
+  MAKE_PROPERTY(node0, get_node0);
+  MAKE_PROPERTY(node1, get_node1);
+  MAKE_PROPERTY(idx0, get_idx0);
+  MAKE_PROPERTY(idx1, get_idx1);
+  MAKE_PROPERTY(part_id0, get_part_id0);
+  MAKE_PROPERTY(part_id1, get_part_id1);
+
 private:
 private:
   static btManifoldPoint _empty;
   static btManifoldPoint _empty;
 
 
@@ -64,6 +72,7 @@ PUBLISHED:
   INLINE int get_num_contacts() const;
   INLINE int get_num_contacts() const;
   INLINE BulletContact get_contact(int idx);
   INLINE BulletContact get_contact(int idx);
   MAKE_SEQ(get_contacts, get_num_contacts, get_contact);
   MAKE_SEQ(get_contacts, get_num_contacts, get_contact);
+  MAKE_SEQ_PROPERTY(contacts, get_num_contacts, get_contact);
 
 
 public:
 public:
 #if BT_BULLET_VERSION >= 281
 #if BT_BULLET_VERSION >= 281

+ 2 - 0
panda/src/bullet/bulletConvexPointCloudShape.h

@@ -36,6 +36,8 @@ PUBLISHED:
 
 
   INLINE int get_num_points() const;
   INLINE int get_num_points() const;
 
 
+  MAKE_PROPERTY(num_points, get_num_points);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 4 - 0
panda/src/bullet/bulletCylinderShape.h

@@ -36,6 +36,10 @@ PUBLISHED:
   INLINE LVecBase3 get_half_extents_without_margin() const;
   INLINE LVecBase3 get_half_extents_without_margin() const;
   INLINE LVecBase3 get_half_extents_with_margin() const;
   INLINE LVecBase3 get_half_extents_with_margin() const;
 
 
+  MAKE_PROPERTY(radius, get_radius);
+  MAKE_PROPERTY(half_extents_without_margin, get_half_extents_without_margin);
+  MAKE_PROPERTY(half_extents_with_margin, get_half_extents_with_margin);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 36 - 0
panda/src/bullet/bulletDebugNode.I

@@ -29,6 +29,15 @@ show_wireframe(bool show) {
   draw_mask_changed();
   draw_mask_changed();
 }
 }
 
 
+/**
+ *
+ */
+INLINE bool BulletDebugNode::
+get_show_wireframe() const {
+
+  return _wireframe;
+}
+
 /**
 /**
  *
  *
  */
  */
@@ -39,6 +48,15 @@ show_constraints(bool show) {
   draw_mask_changed();
   draw_mask_changed();
 }
 }
 
 
+/**
+ *
+ */
+INLINE bool BulletDebugNode::
+get_show_constraints() const {
+
+  return _constraints;
+}
+
 /**
 /**
  *
  *
  */
  */
@@ -49,6 +67,15 @@ show_bounding_boxes(bool show) {
   draw_mask_changed();
   draw_mask_changed();
 }
 }
 
 
+/**
+ *
+ */
+INLINE bool BulletDebugNode::
+get_show_bounding_boxes() const {
+
+  return _bounds;
+}
+
 /**
 /**
  *
  *
  */
  */
@@ -57,3 +84,12 @@ show_normals(bool show) {
 
 
   _drawer._normals = show;
   _drawer._normals = show;
 }
 }
+
+/**
+ *
+ */
+INLINE bool BulletDebugNode::
+get_show_normals() const {
+
+  return _drawer._normals;
+}

+ 9 - 0
panda/src/bullet/bulletDebugNode.h

@@ -35,6 +35,15 @@ PUBLISHED:
   INLINE void show_constraints(bool show);
   INLINE void show_constraints(bool show);
   INLINE void show_bounding_boxes(bool show);
   INLINE void show_bounding_boxes(bool show);
   INLINE void show_normals(bool show);
   INLINE void show_normals(bool show);
+  INLINE bool get_show_wireframe() const;
+  INLINE bool get_show_constraints() const;
+  INLINE bool get_show_bounding_boxes() const;
+  INLINE bool get_show_normals() const;
+
+  MAKE_PROPERTY(wireframe, get_show_wireframe, show_wireframe);
+  MAKE_PROPERTY(constraints, get_show_constraints, show_constraints);
+  MAKE_PROPERTY(bounding_boxes, get_show_bounding_boxes, show_bounding_boxes);
+  MAKE_PROPERTY(normals, get_show_normals, show_normals);
 
 
 public:
 public:
   virtual bool safe_to_flatten() const;
   virtual bool safe_to_flatten() const;

+ 4 - 0
panda/src/bullet/bulletFilterCallbackData.h

@@ -36,6 +36,10 @@ PUBLISHED:
   INLINE void set_collide(bool collide);
   INLINE void set_collide(bool collide);
   INLINE bool get_collide() const;
   INLINE bool get_collide() const;
 
 
+  MAKE_PROPERTY(node_0, get_node_0);
+  MAKE_PROPERTY(node_1, get_node_1);
+  MAKE_PROPERTY(collide, get_collide, set_collide);
+
 private:
 private:
   PandaNode *_node0;
   PandaNode *_node0;
   PandaNode *_node1;
   PandaNode *_node1;

+ 4 - 0
panda/src/bullet/bulletGenericConstraint.h

@@ -61,6 +61,10 @@ PUBLISHED:
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_b() const;
   INLINE CPT(TransformState) get_frame_b() const;
 
 
+  MAKE_PROPERTY(translational_limit_motor, get_translational_limit_motor);
+  MAKE_PROPERTY(frame_a, get_frame_a);
+  MAKE_PROPERTY(frame_b, get_frame_b);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const;
   virtual btTypedConstraint *ptr() const;
 
 

+ 2 - 0
panda/src/bullet/bulletGhostNode.h

@@ -38,6 +38,8 @@ PUBLISHED:
   INLINE int get_num_overlapping_nodes() const;
   INLINE int get_num_overlapping_nodes() const;
   INLINE PandaNode *get_overlapping_node(int idx) const;
   INLINE PandaNode *get_overlapping_node(int idx) const;
   MAKE_SEQ(get_overlapping_nodes, get_num_overlapping_nodes, get_overlapping_node);
   MAKE_SEQ(get_overlapping_nodes, get_num_overlapping_nodes, get_overlapping_node);
+  
+  MAKE_SEQ_PROPERTY(overlapping_nodes, get_num_overlapping_nodes, get_overlapping_node);
 
 
 public:
 public:
   virtual btCollisionObject *get_object() const;
   virtual btCollisionObject *get_object() const;

+ 3 - 0
panda/src/bullet/bulletHelper.h

@@ -51,6 +51,9 @@ PUBLISHED:
 
 
   static void make_texcoords_for_patch(Geom *geom, int resx, int resy);
   static void make_texcoords_for_patch(Geom *geom, int resx, int resy);
 
 
+  MAKE_PROPERTY(sb_index, get_sb_index);
+  MAKE_PROPERTY(sb_flip, get_sb_flip);
+
 private:
 private:
   static PT(InternalName) _sb_index;
   static PT(InternalName) _sb_index;
   static PT(InternalName) _sb_flip;
   static PT(InternalName) _sb_flip;

+ 7 - 0
panda/src/bullet/bulletHingeConstraint.h

@@ -73,6 +73,13 @@ PUBLISHED:
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_b() const;
   INLINE CPT(TransformState) get_frame_b() const;
 
 
+  MAKE_PROPERTY(hinge_angle, get_hinge_angle);
+  MAKE_PROPERTY(lower_limit, get_lower_limit);
+  MAKE_PROPERTY(upper_limit, get_upper_limit);
+  MAKE_PROPERTY(angular_only, get_angular_only, set_angular_only);
+  MAKE_PROPERTY(frame_a, get_frame_a);
+  MAKE_PROPERTY(frame_b, get_frame_b);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const;
   virtual btTypedConstraint *ptr() const;
 
 

+ 24 - 0
panda/src/bullet/bulletManifoldPoint.h

@@ -68,6 +68,30 @@ PUBLISHED:
   INLINE PN_stdfloat get_contact_cfm1() const;
   INLINE PN_stdfloat get_contact_cfm1() const;
   INLINE PN_stdfloat get_contact_cfm2() const;
   INLINE PN_stdfloat get_contact_cfm2() const;
 
 
+  MAKE_PROPERTY(life_time, get_life_time);
+  MAKE_PROPERTY(distance, get_distance);
+  MAKE_PROPERTY(applied_impulse, get_applied_impulse, set_applied_impulse);
+  MAKE_PROPERTY(position_world_on_a, get_position_world_on_a);
+  MAKE_PROPERTY(position_world_on_b, get_position_world_on_b);
+  MAKE_PROPERTY(normal_world_on_b, get_normal_world_on_b);
+  MAKE_PROPERTY(local_point_a, get_local_point_a);
+  MAKE_PROPERTY(local_point_b, get_local_point_b);
+  MAKE_PROPERTY(part_id0, get_part_id0);
+  MAKE_PROPERTY(part_id1, get_part_id1);
+  MAKE_PROPERTY(index0, get_index0);
+  MAKE_PROPERTY(index1, get_index1);
+  MAKE_PROPERTY(lateral_friction_initialized, get_lateral_friction_initialized, set_lateral_friction_initialized);
+  MAKE_PROPERTY(lateral_friction_dir1, get_lateral_friction_dir1, set_lateral_friction_dir1);
+  MAKE_PROPERTY(lateral_friction_dir2, get_lateral_friction_dir2, set_lateral_friction_dir2);
+  MAKE_PROPERTY(contact_motion1, get_contact_motion1, set_contact_motion1);
+  MAKE_PROPERTY(contact_motion2, get_contact_motion2, set_contact_motion2);
+  MAKE_PROPERTY(combined_friction, get_combined_friction, set_combined_friction);
+  MAKE_PROPERTY(combined_restitution, get_combined_restitution, set_combined_restitution);
+  MAKE_PROPERTY(applied_impulse_lateral1, get_applied_impulse_lateral1, set_applied_impulse_lateral1);
+  MAKE_PROPERTY(applied_impulse_lateral2, get_applied_impulse_lateral2, set_applied_impulse_lateral2);
+  MAKE_PROPERTY(contact_cfm1, get_contact_cfm1, set_contact_cfm1);
+  MAKE_PROPERTY(contact_cfm2, get_contact_cfm2, set_contact_cfm2);
+
 public:
 public:
   BulletManifoldPoint(btManifoldPoint &pt);
   BulletManifoldPoint(btManifoldPoint &pt);
 
 

+ 6 - 0
panda/src/bullet/bulletMinkowskiSumShape.h

@@ -43,6 +43,12 @@ PUBLISHED:
 
 
   INLINE PN_stdfloat get_margin() const;
   INLINE PN_stdfloat get_margin() const;
 
 
+  MAKE_PROPERTY(transform_a, get_transform_a, set_transform_a);
+  MAKE_PROPERTY(transform_b, get_transform_b, set_transform_b);
+  MAKE_PROPERTY(shape_a, get_shape_a);
+  MAKE_PROPERTY(shape_b, get_shape_b);
+  MAKE_PROPERTY(margin, get_margin);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 4 - 0
panda/src/bullet/bulletMultiSphereShape.h

@@ -37,6 +37,10 @@ PUBLISHED:
   INLINE LPoint3 get_sphere_pos(int index) const;
   INLINE LPoint3 get_sphere_pos(int index) const;
   INLINE PN_stdfloat get_sphere_radius(int index) const;
   INLINE PN_stdfloat get_sphere_radius(int index) const;
 
 
+  MAKE_PROPERTY(sphere_count, get_sphere_count);
+  MAKE_SEQ_PROPERTY(sphere_pos, get_sphere_count, get_sphere_pos);
+  MAKE_SEQ_PROPERTY(sphere_radius, get_sphere_count, get_sphere_radius);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 6 - 0
panda/src/bullet/bulletPersistentManifold.h

@@ -42,6 +42,12 @@ PUBLISHED:
 
 
   void clear_manifold();
   void clear_manifold();
 
 
+  MAKE_PROPERTY(node0, get_node0);
+  MAKE_PROPERTY(node1, get_node1);
+  MAKE_SEQ_PROPERTY(manifold_points, get_num_manifold_points, get_manifold_point);
+  MAKE_PROPERTY(contact_breaking_threshold, get_contact_breaking_threshold);
+  MAKE_PROPERTY(contact_processing_threshold, get_contact_processing_threshold);
+
 public:
 public:
   BulletPersistentManifold(btPersistentManifold *manifold);
   BulletPersistentManifold(btPersistentManifold *manifold);
 
 

+ 3 - 0
panda/src/bullet/bulletPlaneShape.h

@@ -42,6 +42,9 @@ PUBLISHED:
 
 
   static BulletPlaneShape *make_from_solid(const CollisionPlane *solid);
   static BulletPlaneShape *make_from_solid(const CollisionPlane *solid);
 
 
+  MAKE_PROPERTY(plane_normal, get_plane_normal);
+  MAKE_PROPERTY(plane_constant, get_plane_constant);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 17 - 0
panda/src/bullet/bulletRigidBodyNode.h

@@ -86,6 +86,23 @@ PUBLISHED:
   // Special
   // Special
   bool pick_dirty_flag();
   bool pick_dirty_flag();
 
 
+  MAKE_PROPERTY(mass, get_mass, set_mass);
+  MAKE_PROPERTY(inv_mass, get_inv_mass);
+  MAKE_PROPERTY(inertia, get_inertia, set_inertia);
+  MAKE_PROPERTY(inv_inertia_diag_local, get_inv_inertia_diag_local);
+  MAKE_PROPERTY(inv_inertia_tensor_world, get_inv_inertia_tensor_world);
+  MAKE_PROPERTY(linear_velocity, get_linear_velocity, set_linear_velocity);
+  MAKE_PROPERTY(angular_velocity, get_angular_velocity, set_angular_velocity);
+  MAKE_PROPERTY(linear_damping, get_linear_damping, set_linear_damping);
+  MAKE_PROPERTY(angular_damping, get_angular_damping, set_angular_damping);
+  MAKE_PROPERTY(total_force, get_total_force);
+  MAKE_PROPERTY(total_torque, get_total_torque);
+  MAKE_PROPERTY(linear_sleep_threshold, get_linear_sleep_threshold, set_linear_sleep_threshold);
+  MAKE_PROPERTY(angular_sleep_threshold, get_angular_sleep_threshold, set_angular_sleep_threshold);
+  MAKE_PROPERTY(gravity, get_gravity, set_gravity);
+  MAKE_PROPERTY(linear_factor, get_linear_factor, set_linear_factor);
+  MAKE_PROPERTY(angular_factor, get_angular_factor, set_angular_factor);
+
 public:
 public:
   virtual btCollisionObject *get_object() const;
   virtual btCollisionObject *get_object() const;
 
 

+ 7 - 0
panda/src/bullet/bulletRotationalLimitMotor.h

@@ -50,6 +50,13 @@ PUBLISHED:
   INLINE PN_stdfloat get_current_position() const;
   INLINE PN_stdfloat get_current_position() const;
   INLINE PN_stdfloat get_accumulated_impulse() const;
   INLINE PN_stdfloat get_accumulated_impulse() const;
 
 
+  MAKE_PROPERTY(limited, is_limited);
+  MAKE_PROPERTY(motor_enabled, get_motor_enabled, set_motor_enabled);
+  MAKE_PROPERTY(current_limit, get_current_limit);
+  MAKE_PROPERTY(current_error, get_current_error);
+  MAKE_PROPERTY(current_position, get_current_position);
+  MAKE_PROPERTY(accumulated_impulse, get_accumulated_impulse);
+
 public:
 public:
   BulletRotationalLimitMotor(btRotationalLimitMotor &motor);
   BulletRotationalLimitMotor(btRotationalLimitMotor &motor);
 
 

+ 11 - 1
panda/src/bullet/bulletShape.h

@@ -45,10 +45,20 @@ PUBLISHED:
   PN_stdfloat get_margin() const;
   PN_stdfloat get_margin() const;
 
 
   BoundingSphere get_shape_bounds() const;
   BoundingSphere get_shape_bounds() const;
+  
+  MAKE_PROPERTY(polyhedral, is_polyhedral);
+  MAKE_PROPERTY(convex, is_convex);
+  MAKE_PROPERTY(convex_2d, is_convex_2d);
+  MAKE_PROPERTY(concave, is_concave);
+  MAKE_PROPERTY(infinite, is_infinite);
+  MAKE_PROPERTY(non_moving, is_non_moving);
+  MAKE_PROPERTY(soft_body, is_soft_body);
+  MAKE_PROPERTY(margin, get_margin, set_margin);
+  MAKE_PROPERTY(name, get_name);
+  MAKE_PROPERTY(shape_bounds, get_shape_bounds);
 
 
 public:
 public:
   virtual btCollisionShape *ptr() const = 0;
   virtual btCollisionShape *ptr() const = 0;
-
   LVecBase3 get_local_scale() const;
   LVecBase3 get_local_scale() const;
   void set_local_scale(const LVecBase3 &scale);
   void set_local_scale(const LVecBase3 &scale);
 
 

+ 15 - 0
panda/src/bullet/bulletSliderConstraint.h

@@ -74,6 +74,21 @@ PUBLISHED:
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_a() const;
   INLINE CPT(TransformState) get_frame_b() const;
   INLINE CPT(TransformState) get_frame_b() const;
 
 
+  MAKE_PROPERTY(linear_pos, get_linear_pos);
+  MAKE_PROPERTY(angular_pos, get_angular_pos);
+  MAKE_PROPERTY(lower_linear_limit, get_lower_linear_limit, set_lower_linear_limit);
+  MAKE_PROPERTY(upper_linear_limit, get_upper_linear_limit, set_upper_linear_limit);
+  MAKE_PROPERTY(lower_angular_limit, get_lower_angular_limit, set_lower_angular_limit);
+  MAKE_PROPERTY(upper_angular_limit, get_upper_angular_limit, set_upper_angular_limit);
+  MAKE_PROPERTY(powered_linear_motor, get_powered_linear_motor, set_powered_linear_motor);
+  MAKE_PROPERTY(target_linear_motor_velocity, get_target_linear_motor_velocity, set_target_linear_motor_velocity);
+  MAKE_PROPERTY(max_linear_motor_force, get_max_linear_motor_force, set_max_linear_motor_force);
+  MAKE_PROPERTY(powered_angular_motor, get_powered_angular_motor, set_powered_angular_motor);
+  MAKE_PROPERTY(target_angular_motor_velocity, get_target_angular_motor_velocity, set_target_angular_motor_velocity);
+  MAKE_PROPERTY(max_angular_motor_force, get_max_angular_motor_force, set_max_angular_motor_force);
+  MAKE_PROPERTY(frame_a, get_frame_a);
+  MAKE_PROPERTY(frame_b, get_frame_b);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const;
   virtual btTypedConstraint *ptr() const;
 
 

+ 2 - 2
panda/src/bullet/bulletSoftBodyConfig.I

@@ -113,7 +113,7 @@ set_pressure_coefficient(PN_stdfloat value) {
  * Getter for property kVC.
  * Getter for property kVC.
  */
  */
 INLINE PN_stdfloat BulletSoftBodyConfig::
 INLINE PN_stdfloat BulletSoftBodyConfig::
-get_volume_conversation_coefficient() const {
+get_volume_conservation_coefficient() const {
 
 
   return (PN_stdfloat)_cfg.kVC;
   return (PN_stdfloat)_cfg.kVC;
 }
 }
@@ -122,7 +122,7 @@ get_volume_conversation_coefficient() const {
  * Setter for property kVC.
  * Setter for property kVC.
  */
  */
 INLINE void BulletSoftBodyConfig::
 INLINE void BulletSoftBodyConfig::
-set_volume_conversation_coefficient(PN_stdfloat value) {
+set_volume_conservation_coefficient(PN_stdfloat value) {
 
 
   _cfg.kVC = (btScalar)value;
   _cfg.kVC = (btScalar)value;
 }
 }

+ 28 - 2
panda/src/bullet/bulletSoftBodyConfig.h

@@ -56,7 +56,7 @@ PUBLISHED:
   INLINE void set_drag_coefficient(PN_stdfloat value);
   INLINE void set_drag_coefficient(PN_stdfloat value);
   INLINE void set_lift_coefficient(PN_stdfloat value);
   INLINE void set_lift_coefficient(PN_stdfloat value);
   INLINE void set_pressure_coefficient(PN_stdfloat value);
   INLINE void set_pressure_coefficient(PN_stdfloat value);
-  INLINE void set_volume_conversation_coefficient(PN_stdfloat value);
+  INLINE void set_volume_conservation_coefficient(PN_stdfloat value);
   INLINE void set_dynamic_friction_coefficient(PN_stdfloat value);
   INLINE void set_dynamic_friction_coefficient(PN_stdfloat value);
   INLINE void set_pose_matching_coefficient(PN_stdfloat value);
   INLINE void set_pose_matching_coefficient(PN_stdfloat value);
   INLINE void set_rigid_contacts_hardness(PN_stdfloat value);
   INLINE void set_rigid_contacts_hardness(PN_stdfloat value);
@@ -81,7 +81,7 @@ PUBLISHED:
   INLINE PN_stdfloat get_drag_coefficient() const;
   INLINE PN_stdfloat get_drag_coefficient() const;
   INLINE PN_stdfloat get_lift_coefficient() const;
   INLINE PN_stdfloat get_lift_coefficient() const;
   INLINE PN_stdfloat get_pressure_coefficient() const;
   INLINE PN_stdfloat get_pressure_coefficient() const;
-  INLINE PN_stdfloat get_volume_conversation_coefficient() const;
+  INLINE PN_stdfloat get_volume_conservation_coefficient() const;
   INLINE PN_stdfloat get_dynamic_friction_coefficient() const;
   INLINE PN_stdfloat get_dynamic_friction_coefficient() const;
   INLINE PN_stdfloat get_pose_matching_coefficient() const;
   INLINE PN_stdfloat get_pose_matching_coefficient() const;
   INLINE PN_stdfloat get_rigid_contacts_hardness() const;
   INLINE PN_stdfloat get_rigid_contacts_hardness() const;
@@ -101,6 +101,32 @@ PUBLISHED:
   INLINE int get_drift_solver_iterations() const;
   INLINE int get_drift_solver_iterations() const;
   INLINE int get_cluster_solver_iterations() const;
   INLINE int get_cluster_solver_iterations() const;
 
 
+  MAKE_PROPERTY(aero_model, get_aero_model, set_aero_model);
+  MAKE_PROPERTY(velocities_correction_factor, get_velocities_correction_factor, set_velocities_correction_factor);
+  MAKE_PROPERTY(damping_coefficient, get_damping_coefficient, set_damping_coefficient);
+  MAKE_PROPERTY(drag_coefficient, get_drag_coefficient, set_drag_coefficient);
+  MAKE_PROPERTY(lift_coefficient, get_lift_coefficient, set_lift_coefficient);
+  MAKE_PROPERTY(pressure_coefficient, get_pressure_coefficient, set_pressure_coefficient);
+  MAKE_PROPERTY(volume_conservation_coefficient, get_volume_conservation_coefficient, set_volume_conservation_coefficient);
+  MAKE_PROPERTY(dynamic_friction_coefficient, get_dynamic_friction_coefficient, set_dynamic_friction_coefficient);
+  MAKE_PROPERTY(pose_matching_coefficient, get_pose_matching_coefficient, set_pose_matching_coefficient);
+  MAKE_PROPERTY(rigid_contacts_hardness, get_rigid_contacts_hardness, set_rigid_contacts_hardness);
+  MAKE_PROPERTY(kinetic_contacts_hardness, get_kinetic_contacts_hardness, set_kinetic_contacts_hardness);
+  MAKE_PROPERTY(soft_contacts_hardness, get_soft_contacts_hardness, set_soft_contacts_hardness);
+  MAKE_PROPERTY(anchors_hardness, get_anchors_hardness, set_anchors_hardness);
+  MAKE_PROPERTY(soft_vs_rigid_hardness, get_soft_vs_rigid_hardness, set_soft_vs_rigid_hardness);
+  MAKE_PROPERTY(soft_vs_kinetic_hardness, get_soft_vs_kinetic_hardness, set_soft_vs_kinetic_hardness);
+  MAKE_PROPERTY(soft_vs_soft_hardness, get_soft_vs_soft_hardness, set_soft_vs_soft_hardness);
+  MAKE_PROPERTY(soft_vs_rigid_impulse_split, get_soft_vs_rigid_impulse_split, set_soft_vs_rigid_impulse_split);
+  MAKE_PROPERTY(soft_vs_kinetic_impulse_split, get_soft_vs_kinetic_impulse_split, set_soft_vs_kinetic_impulse_split);
+  MAKE_PROPERTY(soft_vs_soft_impulse_split, get_soft_vs_soft_impulse_split, set_soft_vs_soft_impulse_split);
+  MAKE_PROPERTY(maxvolume, get_maxvolume, set_maxvolume);
+  MAKE_PROPERTY(timescale, get_timescale, set_timescale);
+  MAKE_PROPERTY(positions_solver_iterations, get_positions_solver_iterations, set_positions_solver_iterations);
+  MAKE_PROPERTY(velocities_solver_iterations, get_velocities_solver_iterations, set_velocities_solver_iterations);
+  MAKE_PROPERTY(drift_solver_iterations, get_drift_solver_iterations, set_drift_solver_iterations);
+  MAKE_PROPERTY(cluster_solver_iterations, get_cluster_solver_iterations, set_cluster_solver_iterations);
+
 public:
 public:
   BulletSoftBodyConfig(btSoftBody::Config &cfg);
   BulletSoftBodyConfig(btSoftBody::Config &cfg);
 
 

+ 6 - 5
panda/src/bullet/bulletSoftBodyMaterial.h

@@ -27,16 +27,17 @@ PUBLISHED:
   INLINE ~BulletSoftBodyMaterial();
   INLINE ~BulletSoftBodyMaterial();
   INLINE static BulletSoftBodyMaterial empty();
   INLINE static BulletSoftBodyMaterial empty();
 
 
-  INLINE void set_linear_stiffness(PN_stdfloat value);
   INLINE PN_stdfloat get_linear_stiffness() const;
   INLINE PN_stdfloat get_linear_stiffness() const;
-  MAKE_PROPERTY(linear_stiffness, get_linear_stiffness, set_linear_stiffness);
+  INLINE void set_linear_stiffness(PN_stdfloat value);
   
   
-  INLINE void set_angular_stiffness(PN_stdfloat value);
   INLINE PN_stdfloat get_angular_stiffness() const;
   INLINE PN_stdfloat get_angular_stiffness() const;
-  MAKE_PROPERTY(angular_stiffness, get_angular_stiffness, set_angular_stiffness);
+  INLINE void set_angular_stiffness(PN_stdfloat value);
   
   
-  INLINE void set_volume_preservation(PN_stdfloat value);
   INLINE PN_stdfloat get_volume_preservation() const;
   INLINE PN_stdfloat get_volume_preservation() const;
+  INLINE void set_volume_preservation(PN_stdfloat value);
+  
+  MAKE_PROPERTY(linear_stiffness, get_linear_stiffness, set_linear_stiffness);
+  MAKE_PROPERTY(angular_stiffness, get_angular_stiffness, set_angular_stiffness);
   MAKE_PROPERTY(volume_preservation, get_volume_preservation, set_volume_preservation);
   MAKE_PROPERTY(volume_preservation, get_volume_preservation, set_volume_preservation);
 
 
 public:
 public:

+ 15 - 0
panda/src/bullet/bulletSoftBodyNode.h

@@ -50,6 +50,13 @@ PUBLISHED:
   INLINE PN_stdfloat get_area() const;
   INLINE PN_stdfloat get_area() const;
   INLINE int is_attached() const;
   INLINE int is_attached() const;
 
 
+  MAKE_PROPERTY(pos, get_pos);
+  MAKE_PROPERTY(velocity, get_velocity);
+  MAKE_PROPERTY(normal, get_normal);
+  MAKE_PROPERTY(inv_mass, get_inv_mass);
+  MAKE_PROPERTY(area, get_area);
+  MAKE_PROPERTY(attached, is_attached);
+
 public:
 public:
   BulletSoftBodyNodeElement(btSoftBody::Node &node);
   BulletSoftBodyNodeElement(btSoftBody::Node &node);
 
 
@@ -203,6 +210,14 @@ PUBLISHED:
       const char *face,
       const char *face,
       const char *node);
       const char *node);
 
 
+  MAKE_PROPERTY(cfg, get_cfg);
+  MAKE_PROPERTY(world_info, get_world_info);
+  MAKE_PROPERTY(wind_velocity, get_wind_velocity, set_wind_velocity);
+  MAKE_PROPERTY(aabb, get_aabb);
+  MAKE_PROPERTY(num_clusters, get_num_clusters);
+  MAKE_SEQ_PROPERTY(materials, get_num_materials, get_material);
+  MAKE_SEQ_PROPERTY(nodes, get_num_nodes, get_node);
+
 public:
 public:
   virtual btCollisionObject *get_object() const;
   virtual btCollisionObject *get_object() const;
 
 

+ 2 - 0
panda/src/bullet/bulletSoftBodyShape.h

@@ -31,6 +31,8 @@ PUBLISHED:
 
 
   BulletSoftBodyNode *get_body() const;
   BulletSoftBodyNode *get_body() const;
 
 
+  MAKE_PROPERTY(body, get_body);
+
 public:
 public:
   BulletSoftBodyShape(btSoftBodyCollisionShape *shapePtr);
   BulletSoftBodyShape(btSoftBodyCollisionShape *shapePtr);
 
 

+ 6 - 0
panda/src/bullet/bulletSoftBodyWorldInfo.h

@@ -43,6 +43,12 @@ PUBLISHED:
 
 
   void garbage_collect(int lifetime=256);
   void garbage_collect(int lifetime=256);
 
 
+  MAKE_PROPERTY(air_density, get_air_density, set_air_density);
+  MAKE_PROPERTY(water_density, get_water_density, set_water_density);
+  MAKE_PROPERTY(water_offset, get_water_offset, set_water_offset);
+  MAKE_PROPERTY(water_normal, get_water_normal, set_water_normal);
+  MAKE_PROPERTY(gravity, get_gravity, set_gravity);
+
 public:
 public:
   BulletSoftBodyWorldInfo(btSoftBodyWorldInfo &_info);
   BulletSoftBodyWorldInfo(btSoftBodyWorldInfo &_info);
 
 

+ 2 - 0
panda/src/bullet/bulletSphereShape.h

@@ -40,6 +40,8 @@ PUBLISHED:
 
 
   static BulletSphereShape *make_from_solid(const CollisionSphere *solid);
   static BulletSphereShape *make_from_solid(const CollisionSphere *solid);
 
 
+  MAKE_PROPERTY(radius, get_radius);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 3 - 0
panda/src/bullet/bulletSphericalConstraint.h

@@ -48,6 +48,9 @@ PUBLISHED:
   LPoint3 get_pivot_in_a() const;
   LPoint3 get_pivot_in_a() const;
   LPoint3 get_pivot_in_b() const;
   LPoint3 get_pivot_in_b() const;
 
 
+  MAKE_PROPERTY(pivot_a, get_pivot_in_a, set_pivot_a);
+  MAKE_PROPERTY(pivot_b, get_pivot_in_b, set_pivot_b);
+
 public:
 public:
   virtual btTypedConstraint *ptr() const;
   virtual btTypedConstraint *ptr() const;
 
 

+ 2 - 0
panda/src/bullet/bulletTickCallbackData.h

@@ -30,6 +30,8 @@ PUBLISHED:
 
 
   INLINE PN_stdfloat get_timestep() const;
   INLINE PN_stdfloat get_timestep() const;
 
 
+  MAKE_PROPERTY(timestep, get_timestep);
+
 private:
 private:
   btScalar _timestep;
   btScalar _timestep;
 
 

+ 6 - 2
panda/src/bullet/bulletTranslationalLimitMotor.h

@@ -32,8 +32,8 @@ PUBLISHED:
 
 
   INLINE void set_motor_enabled(int axis, bool enable);
   INLINE void set_motor_enabled(int axis, bool enable);
   INLINE void set_low_limit(const LVecBase3 &limit);
   INLINE void set_low_limit(const LVecBase3 &limit);
-  INLINE void set_high_limit(const LVecBase3 & limit);
-  INLINE void set_target_velocity(const LVecBase3&velocity);
+  INLINE void set_high_limit(const LVecBase3 &limit);
+  INLINE void set_target_velocity(const LVecBase3 &velocity);
   INLINE void set_max_motor_force(const LVecBase3 &force);
   INLINE void set_max_motor_force(const LVecBase3 &force);
   INLINE void set_damping(PN_stdfloat damping);
   INLINE void set_damping(PN_stdfloat damping);
   INLINE void set_softness(PN_stdfloat softness);
   INLINE void set_softness(PN_stdfloat softness);
@@ -49,6 +49,10 @@ PUBLISHED:
   INLINE LPoint3 get_current_diff() const;
   INLINE LPoint3 get_current_diff() const;
   INLINE LVector3 get_accumulated_impulse() const;
   INLINE LVector3 get_accumulated_impulse() const;
 
 
+  MAKE_PROPERTY(current_error, get_current_error);
+  MAKE_PROPERTY(current_diff, get_current_diff);
+  MAKE_PROPERTY(accumulated_impulse, get_accumulated_impulse);
+
 public:
 public:
   BulletTranslationalLimitMotor(btTranslationalLimitMotor &motor);
   BulletTranslationalLimitMotor(btTranslationalLimitMotor &motor);
 
 

+ 3 - 0
panda/src/bullet/bulletTriangleMesh.h

@@ -55,6 +55,9 @@ PUBLISHED:
   virtual void output(ostream &out) const;
   virtual void output(ostream &out) const;
   virtual void write(ostream &out, int indent_level) const;
   virtual void write(ostream &out, int indent_level) const;
 
 
+  MAKE_PROPERTY(num_triangles, get_num_triangles);
+  MAKE_PROPERTY(welding_distance, get_welding_distance, set_welding_distance);
+
 public:
 public:
   INLINE btTriangleMesh *ptr() const;
   INLINE btTriangleMesh *ptr() const;
 
 

+ 3 - 0
panda/src/bullet/bulletTriangleMeshShape.h

@@ -41,6 +41,9 @@ PUBLISHED:
   INLINE bool is_static() const;
   INLINE bool is_static() const;
   INLINE bool is_dynamic() const;
   INLINE bool is_dynamic() const;
 
 
+  MAKE_PROPERTY(static, is_static);
+  MAKE_PROPERTY(dynamic, is_dynamic);
+
 public:
 public:
   virtual btCollisionShape *ptr() const;
   virtual btCollisionShape *ptr() const;
 
 

+ 13 - 0
panda/src/bullet/bulletVehicle.h

@@ -46,6 +46,13 @@ PUBLISHED:
   INLINE PN_stdfloat get_friction_slip() const;
   INLINE PN_stdfloat get_friction_slip() const;
   INLINE PN_stdfloat get_max_suspension_force() const;
   INLINE PN_stdfloat get_max_suspension_force() const;
 
 
+  MAKE_PROPERTY(suspension_stiffness, get_suspension_stiffness, set_suspension_stiffness);
+  MAKE_PROPERTY(suspension_compression, get_suspension_compression, set_suspension_compression);
+  MAKE_PROPERTY(suspension_damping, get_suspension_damping, set_suspension_damping);
+  MAKE_PROPERTY(max_suspension_travel_cm, get_max_suspension_travel_cm, set_max_suspension_travel_cm);
+  MAKE_PROPERTY(friction_slip, get_friction_slip, set_friction_slip);
+  MAKE_PROPERTY(max_suspension_force, get_max_suspension_force, set_max_suspension_force);
+
 private:
 private:
   btRaycastVehicle::btVehicleTuning _;
   btRaycastVehicle::btVehicleTuning _;
 
 
@@ -87,6 +94,12 @@ PUBLISHED:
   // Tuning
   // Tuning
   INLINE BulletVehicleTuning &get_tuning();
   INLINE BulletVehicleTuning &get_tuning();
 
 
+  MAKE_PROPERTY(chassis, get_chassis);
+  MAKE_PROPERTY(current_speed_km_hour, get_current_speed_km_hour);
+  MAKE_PROPERTY(forward_vector, get_forward_vector);
+  MAKE_SEQ_PROPERTY(wheels, get_num_wheels, get_wheel);
+  MAKE_PROPERTY(tuning, get_tuning);
+
 public:
 public:
   INLINE btRaycastVehicle *get_vehicle() const;
   INLINE btRaycastVehicle *get_vehicle() const;
 
 

+ 35 - 0
panda/src/bullet/bulletWheel.h

@@ -39,6 +39,15 @@ PUBLISHED:
   INLINE LPoint3 get_hard_point_ws() const;
   INLINE LPoint3 get_hard_point_ws() const;
   INLINE PandaNode *get_ground_object() const;
   INLINE PandaNode *get_ground_object() const;
 
 
+  MAKE_PROPERTY(in_contact, is_in_contact);
+  MAKE_PROPERTY(suspension_length, get_suspension_length);
+  MAKE_PROPERTY(contact_normal_ws, get_contact_normal_ws);
+  MAKE_PROPERTY(wheel_direction_ws, get_wheel_direction_ws);
+  MAKE_PROPERTY(wheel_axle_ws, get_wheel_axle_ws);
+  MAKE_PROPERTY(contact_point_ws, get_contact_point_ws);
+  MAKE_PROPERTY(hard_point_ws, get_hard_point_ws);
+  MAKE_PROPERTY(ground_object, get_ground_object);
+
 public:
 public:
   BulletWheelRaycastInfo(btWheelInfo::RaycastInfo &info);
   BulletWheelRaycastInfo(btWheelInfo::RaycastInfo &info);
 
 
@@ -105,6 +114,32 @@ PUBLISHED:
   PandaNode *get_node() const;
   PandaNode *get_node() const;
   BulletWheelRaycastInfo get_raycast_info() const;
   BulletWheelRaycastInfo get_raycast_info() const;
 
 
+  MAKE_PROPERTY(raycast_info, get_raycast_info);
+  MAKE_PROPERTY(suspension_rest_length, get_suspension_rest_length);
+  MAKE_PROPERTY(suspension_stiffness, get_suspension_stiffness, set_suspension_stiffness);
+  MAKE_PROPERTY(max_suspension_travel_cm, get_max_suspension_travel_cm, set_max_suspension_travel_cm);
+  MAKE_PROPERTY(friction_slip, get_friction_slip, set_friction_slip);
+  MAKE_PROPERTY(max_suspension_force, get_max_suspension_force, set_max_suspension_force);
+  MAKE_PROPERTY(wheels_damping_compression, get_wheels_damping_compression, set_wheels_damping_compression);
+  MAKE_PROPERTY(wheels_damping_relaxation, get_wheels_damping_relaxation, set_wheels_damping_relaxation);
+  MAKE_PROPERTY(roll_influence, get_roll_influence, set_roll_influence);
+  MAKE_PROPERTY(wheel_radius, get_wheel_radius, set_wheel_radius);
+  MAKE_PROPERTY(steering, get_steering, set_steering);
+  MAKE_PROPERTY(rotation, get_rotation, set_rotation);
+  MAKE_PROPERTY(delta_rotation, get_delta_rotation, set_delta_rotation);
+  MAKE_PROPERTY(engine_force, get_engine_force, set_engine_force);
+  MAKE_PROPERTY(brake, get_brake, set_brake);
+  MAKE_PROPERTY(skid_info, get_skid_info, set_skid_info);
+  MAKE_PROPERTY(wheels_suspension_force, get_wheels_suspension_force, set_wheels_suspension_force);
+  MAKE_PROPERTY(suspension_relative_velocity, get_suspension_relative_velocity, set_suspension_relative_velocity);
+  MAKE_PROPERTY(clipped_inv_connection_point_cs, get_clipped_inv_connection_point_cs, set_clipped_inv_connection_point_cs);
+  MAKE_PROPERTY(chassis_connection_point_cs, get_chassis_connection_point_cs, set_chassis_connection_point_cs);
+  MAKE_PROPERTY(wheel_direction_cs, get_wheel_direction_cs, set_wheel_direction_cs);
+  MAKE_PROPERTY(wheel_axle_cs, get_wheel_axle_cs, set_wheel_axle_cs);
+  MAKE_PROPERTY(world_transform, get_world_transform, set_world_transform);
+  MAKE_PROPERTY(front_wheel, is_front_wheel, set_front_wheel);
+  MAKE_PROPERTY(node, get_node, set_node);
+
 public:
 public:
   BulletWheel(btWheelInfo &info);
   BulletWheel(btWheelInfo &info);
 
 

+ 9 - 0
panda/src/bullet/bulletWorld.I

@@ -81,6 +81,15 @@ get_debug_node() const {
   return _debug;
   return _debug;
 }
 }
 
 
+/**
+ *
+ */
+INLINE bool BulletWorld::
+has_debug_node() const {
+
+  return _debug != NULL;
+}
+
 /**
 /**
  *
  *
  */
  */

+ 12 - 0
panda/src/bullet/bulletWorld.h

@@ -65,6 +65,7 @@ PUBLISHED:
   INLINE void set_debug_node(BulletDebugNode *node);
   INLINE void set_debug_node(BulletDebugNode *node);
   INLINE void clear_debug_node();
   INLINE void clear_debug_node();
   INLINE BulletDebugNode *get_debug_node() const;
   INLINE BulletDebugNode *get_debug_node() const;
+  INLINE bool has_debug_node() const;
 
 
   // AttachRemove
   // AttachRemove
   void attach(TypedObject *object);
   void attach(TypedObject *object);
@@ -159,6 +160,17 @@ PUBLISHED:
     FA_callback,
     FA_callback,
   };
   };
 
 
+  MAKE_PROPERTY(gravity, get_gravity, set_gravity);
+  MAKE_PROPERTY(world_info, get_world_info);
+  MAKE_PROPERTY2(debug_node, has_debug_node, get_debug_node, set_debug_node, clear_debug_node);
+  MAKE_SEQ_PROPERTY(ghosts, get_num_ghosts, get_ghost);
+  MAKE_SEQ_PROPERTY(rigid_bodies, get_num_rigid_bodies, get_rigid_body);
+  MAKE_SEQ_PROPERTY(soft_bodies, get_num_soft_bodies, get_soft_body);
+  MAKE_SEQ_PROPERTY(characters, get_num_characters, get_character);
+  MAKE_SEQ_PROPERTY(vehicles, get_num_vehicles, get_vehicle);
+  MAKE_SEQ_PROPERTY(constraints, get_num_constraints, get_constraint);
+  MAKE_SEQ_PROPERTY(manifolds, get_num_manifolds, get_manifold);
+
 PUBLISHED: // Deprecated methods, will become private soon
 PUBLISHED: // Deprecated methods, will become private soon
   void attach_ghost(BulletGhostNode *node);
   void attach_ghost(BulletGhostNode *node);
   void remove_ghost(BulletGhostNode *node);
   void remove_ghost(BulletGhostNode *node);

+ 6 - 0
panda/src/text/config_text.cxx

@@ -48,6 +48,12 @@ ConfigVariableBool text_dynamic_merge
           "operation.  Usually it's a performance "
           "operation.  Usually it's a performance "
           "advantage to keep this true.  See TextNode::set_flatten_flags()."));
           "advantage to keep this true.  See TextNode::set_flatten_flags()."));
 
 
+ConfigVariableBool text_kerning
+("text-kerning", false,
+ PRC_DESC("Set this true to enable kerning when the font provides kerning "
+          "tables.  This can result in more aesthetically pleasing spacing "
+          "between individual glyphs."));
+
 ConfigVariableInt text_anisotropic_degree
 ConfigVariableInt text_anisotropic_degree
 ("text-anisotropic-degree", 1,
 ("text-anisotropic-degree", 1,
  PRC_DESC("This is the default anisotropic-degree that is set on dynamic "
  PRC_DESC("This is the default anisotropic-degree that is set on dynamic "

+ 1 - 0
panda/src/text/config_text.h

@@ -30,6 +30,7 @@ NotifyCategoryDecl(text, EXPCL_PANDA_TEXT, EXPTP_PANDA_TEXT);
 
 
 extern ConfigVariableBool text_flatten;
 extern ConfigVariableBool text_flatten;
 extern ConfigVariableBool text_dynamic_merge;
 extern ConfigVariableBool text_dynamic_merge;
+extern ConfigVariableBool text_kerning;
 extern ConfigVariableInt text_anisotropic_degree;
 extern ConfigVariableInt text_anisotropic_degree;
 extern ConfigVariableInt text_texture_margin;
 extern ConfigVariableInt text_texture_margin;
 extern ConfigVariableDouble text_poly_margin;
 extern ConfigVariableDouble text_poly_margin;

+ 26 - 0
panda/src/text/dynamicTextFont.cxx

@@ -278,6 +278,32 @@ get_glyph(int character, CPT(TextGlyph) &glyph) {
   return (glyph_index != 0);
   return (glyph_index != 0);
 }
 }
 
 
+/**
+ * Returns the amount by which to offset the second glyph when it directly
+ * follows the first glyph.  This is an additional offset that is added on top
+ * of the advance.
+ */
+PN_stdfloat DynamicTextFont::
+get_kerning(int first, int second) const {
+  if (!_is_valid) {
+    return 0;
+  }
+
+  FT_Face face = acquire_face();
+  if (!FT_HAS_KERNING(face)) {
+    release_face(face);
+    return 0;
+  }
+
+  int first_index = FT_Get_Char_Index(face, first);
+  int second_index = FT_Get_Char_Index(face, second);
+
+  FT_Vector delta;
+  FT_Get_Kerning(face, first_index, second_index, FT_KERNING_DEFAULT, &delta);
+  release_face(face);
+
+  return delta.x / (_font_pixels_per_unit * 64);
+}
 
 
 /**
 /**
  * Called from both constructors to set up some initial values.
  * Called from both constructors to set up some initial values.

+ 1 - 0
panda/src/text/dynamicTextFont.h

@@ -123,6 +123,7 @@ PUBLISHED:
 
 
 public:
 public:
   virtual bool get_glyph(int character, CPT(TextGlyph) &glyph);
   virtual bool get_glyph(int character, CPT(TextGlyph) &glyph);
+  virtual PN_stdfloat get_kerning(int first, int second) const;
 
 
 private:
 private:
   void initialize();
   void initialize();

+ 18 - 1
panda/src/text/textAssembler.cxx

@@ -609,6 +609,8 @@ assemble_text() {
  * Returns the width of a single character, according to its associated font.
  * Returns the width of a single character, according to its associated font.
  * This also correctly calculates the width of cheesy ligatures and accented
  * This also correctly calculates the width of cheesy ligatures and accented
  * characters, which may not exist in the font as such.
  * characters, which may not exist in the font as such.
+ *
+ * This does not take kerning into account, however.
  */
  */
 PN_stdfloat TextAssembler::
 PN_stdfloat TextAssembler::
 calc_width(wchar_t character, const TextProperties &properties) {
 calc_width(wchar_t character, const TextProperties &properties) {
@@ -1399,6 +1401,9 @@ assemble_row(TextAssembler::TextRow &row,
   PN_stdfloat xpos = 0.0f;
   PN_stdfloat xpos = 0.0f;
   align = TextProperties::A_left;
   align = TextProperties::A_left;
 
 
+  // Remember previous character, for kerning.
+  int prev_char = -1;
+
   bool underscore = false;
   bool underscore = false;
   PN_stdfloat underscore_start = 0.0f;
   PN_stdfloat underscore_start = 0.0f;
   const TextProperties *underscore_properties = NULL;
   const TextProperties *underscore_properties = NULL;
@@ -1450,11 +1455,13 @@ assemble_row(TextAssembler::TextRow &row,
     if (character == ' ') {
     if (character == ' ') {
       // A space is a special case.
       // A space is a special case.
       xpos += properties->get_glyph_scale() * properties->get_text_scale() * font->get_space_advance();
       xpos += properties->get_glyph_scale() * properties->get_text_scale() * font->get_space_advance();
+      prev_char = -1;
 
 
     } else if (character == '\t') {
     } else if (character == '\t') {
       // So is a tab character.
       // So is a tab character.
       PN_stdfloat tab_width = properties->get_tab_width();
       PN_stdfloat tab_width = properties->get_tab_width();
       xpos = (floor(xpos / tab_width) + 1.0f) * tab_width;
       xpos = (floor(xpos / tab_width) + 1.0f) * tab_width;
+      prev_char = -1;
 
 
     } else if (character == text_soft_hyphen_key) {
     } else if (character == text_soft_hyphen_key) {
       // And so is the 'soft-hyphen' key character.
       // And so is the 'soft-hyphen' key character.
@@ -1493,6 +1500,7 @@ assemble_row(TextAssembler::TextRow &row,
       placed_glyphs.push_back(placement);
       placed_glyphs.push_back(placement);
 
 
       xpos += advance * glyph_scale;
       xpos += advance * glyph_scale;
+      prev_char = -1;
 
 
     } else {
     } else {
       // A printable character.
       // A printable character.
@@ -1521,13 +1529,22 @@ assemble_row(TextAssembler::TextRow &row,
           << "\n";
           << "\n";
       }
       }
 
 
+      glyph_scale *= properties->get_glyph_scale() * properties->get_text_scale();
+
+      // Add the kerning delta.
+      if (text_kerning) {
+        if (prev_char != -1) {
+          xpos += font->get_kerning(prev_char, character) * glyph_scale;
+        }
+        prev_char = character;
+      }
+
       // Build up a GlyphPlacement, indicating all of the Geoms that go into
       // Build up a GlyphPlacement, indicating all of the Geoms that go into
       // this character.  Normally, there is only one Geom per character, but
       // this character.  Normally, there is only one Geom per character, but
       // it may involve multiple Geoms if we need to add cheesy accents or
       // it may involve multiple Geoms if we need to add cheesy accents or
       // ligatures.
       // ligatures.
       GlyphPlacement placement;
       GlyphPlacement placement;
 
 
-      glyph_scale *= properties->get_glyph_scale() * properties->get_text_scale();
       placement._glyph = NULL;
       placement._glyph = NULL;
       placement._scale = glyph_scale;
       placement._scale = glyph_scale;
       placement._xpos = xpos;
       placement._xpos = xpos;

+ 10 - 0
panda/src/text/textFont.cxx

@@ -54,6 +54,16 @@ TextFont::
 ~TextFont() {
 ~TextFont() {
 }
 }
 
 
+/**
+ * Returns the amount by which to offset the second glyph when it directly
+ * follows the first glyph.  This is an additional offset that is added on top
+ * of the advance.
+ */
+PN_stdfloat TextFont::
+get_kerning(int first, int second) const {
+  return 0;
+}
+
 /**
 /**
  *
  *
  */
  */

+ 2 - 0
panda/src/text/textFont.h

@@ -74,6 +74,8 @@ PUBLISHED:
 
 
   INLINE CPT(TextGlyph) get_glyph(int character);
   INLINE CPT(TextGlyph) get_glyph(int character);
 
 
+  virtual PN_stdfloat get_kerning(int first, int second) const;
+
   virtual void write(ostream &out, int indent_level) const;
   virtual void write(ostream &out, int indent_level) const;
 
 
 public:
 public: