aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
diff options
context:
space:
mode:
authorRobert Adams2012-10-05 15:33:17 -0700
committerRobert Adams2012-10-11 14:01:03 -0700
commit87825b0abee76c28dcffdaa2c532779b813b6d14 (patch)
tree1028e20a0c2cd8ddea9a60b0b013fa1db69daa74 /OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
parentUpdated Robust.HG.ini.example. Thanks Austin Tate. (diff)
downloadopensim-SC_OLD-87825b0abee76c28dcffdaa2c532779b813b6d14.zip
opensim-SC_OLD-87825b0abee76c28dcffdaa2c532779b813b6d14.tar.gz
opensim-SC_OLD-87825b0abee76c28dcffdaa2c532779b813b6d14.tar.bz2
opensim-SC_OLD-87825b0abee76c28dcffdaa2c532779b813b6d14.tar.xz
BulletSim: Fix crash when linking large physical linksets.
Properly remove and restore linkage constraints when upgrading a prim's mesh to a hull. Lots more debug logging. Definitions and use of Bullet structure dumping. Centralize detail logging so a Flush() can be added for debugging.
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs')
-rw-r--r--OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
index f7b68ba..98a18a1 100644
--- a/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
@@ -196,7 +196,7 @@ public sealed class BSPrim : BSPhysObject
196 _isSelected = value; 196 _isSelected = value;
197 PhysicsScene.TaintedObject("BSPrim.setSelected", delegate() 197 PhysicsScene.TaintedObject("BSPrim.setSelected", delegate()
198 { 198 {
199 // DetailLog("{0},BSPrim.selected,taint,selected={1}", LocalID, _isSelected); 199 DetailLog("{0},BSPrim.selected,taint,selected={1}", LocalID, _isSelected);
200 SetObjectDynamic(false); 200 SetObjectDynamic(false);
201 }); 201 });
202 } 202 }
@@ -620,8 +620,10 @@ public sealed class BSPrim : BSPhysObject
620 BulletSimAPI.UpdateInertiaTensor2(BSBody.ptr); 620 BulletSimAPI.UpdateInertiaTensor2(BSBody.ptr);
621 // There can be special things needed for implementing linksets 621 // There can be special things needed for implementing linksets
622 Linkset.MakeStatic(this); 622 Linkset.MakeStatic(this);
623 // The activation state is 'disabled' so Bullet will not try to act on it 623 // The activation state is 'disabled' so Bullet will not try to act on it.
624 BulletSimAPI.ForceActivationState2(BSBody.ptr, ActivationState.DISABLE_SIMULATION); 624 // BulletSimAPI.ForceActivationState2(BSBody.ptr, ActivationState.DISABLE_SIMULATION);
625 // Start it out sleeping and physical actions could wake it up.
626 BulletSimAPI.ForceActivationState2(BSBody.ptr, ActivationState.ISLAND_SLEEPING);
625 627
626 BSBody.collisionFilter = CollisionFilterGroups.StaticObjectFilter; 628 BSBody.collisionFilter = CollisionFilterGroups.StaticObjectFilter;
627 BSBody.collisionMask = CollisionFilterGroups.StaticObjectMask; 629 BSBody.collisionMask = CollisionFilterGroups.StaticObjectMask;
@@ -1204,6 +1206,7 @@ public sealed class BSPrim : BSPhysObject
1204 { 1206 {
1205 // Called if the current prim body is about to be destroyed. 1207 // Called if the current prim body is about to be destroyed.
1206 // Remove all the physical dependencies on the old body. 1208 // Remove all the physical dependencies on the old body.
1209 // (Maybe someday make the changing of BSShape an event handled by BSLinkset.)
1207 needToRestoreLinkset = Linkset.RemoveBodyDependencies(this); 1210 needToRestoreLinkset = Linkset.RemoveBodyDependencies(this);
1208 }); 1211 });
1209 1212