aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
diff options
context:
space:
mode:
authorRobert Adams2013-05-24 16:23:10 -0700
committerRobert Adams2013-05-24 16:23:10 -0700
commit4979940def5561015cb56bc660c6ec721722b9fc (patch)
treedca7c753622feb96e3ffdf6561247c4b4532d44b /OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
parentMeshmerizer: add INI parameter to enable DEBUG mesh detail logging. (diff)
downloadopensim-SC-4979940def5561015cb56bc660c6ec721722b9fc.zip
opensim-SC-4979940def5561015cb56bc660c6ec721722b9fc.tar.gz
opensim-SC-4979940def5561015cb56bc660c6ec721722b9fc.tar.bz2
opensim-SC-4979940def5561015cb56bc660c6ec721722b9fc.tar.xz
BulletSim: properly set mesh hash key in use tracking structure.
Shouldn't see any functional difference.
Diffstat (limited to '')
-rwxr-xr-xOpenSim/Region/Physics/BulletSPlugin/BSShapes.cs5
1 files changed, 4 insertions, 1 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
index 48f1394..81edc12 100755
--- a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
@@ -578,7 +578,6 @@ public class BSShapeHull : BSShape
578 PrimitiveBaseShape pbs, OMV.Vector3 size, float lod) 578 PrimitiveBaseShape pbs, OMV.Vector3 size, float lod)
579 { 579 {
580 BulletShape newShape = new BulletShape(); 580 BulletShape newShape = new BulletShape();
581 newShape.shapeKey = newHullKey;
582 581
583 IMesh meshData = null; 582 IMesh meshData = null;
584 List<List<OMV.Vector3>> allHulls = null; 583 List<List<OMV.Vector3>> allHulls = null;
@@ -782,6 +781,7 @@ public class BSShapeHull : BSShape
782 // create the hull data structure in Bullet 781 // create the hull data structure in Bullet
783 newShape = physicsScene.PE.CreateHullShape(physicsScene.World, hullCount, convHulls); 782 newShape = physicsScene.PE.CreateHullShape(physicsScene.World, hullCount, convHulls);
784 } 783 }
784 newShape.shapeKey = newHullKey;
785 return newShape; 785 return newShape;
786 } 786 }
787 // Callback from convex hull creater with a newly created hull. 787 // Callback from convex hull creater with a newly created hull.
@@ -906,6 +906,7 @@ public class BSShapeCompound : BSShape
906 } 906 }
907 else 907 else
908 { 908 {
909 // Didn't find it in the lists of specific types. It could be compound.
909 if (physicsScene.PE.IsCompound(pShape)) 910 if (physicsScene.PE.IsCompound(pShape))
910 { 911 {
911 BSShapeCompound recursiveCompound = new BSShapeCompound(pShape); 912 BSShapeCompound recursiveCompound = new BSShapeCompound(pShape);
@@ -913,6 +914,7 @@ public class BSShapeCompound : BSShape
913 } 914 }
914 else 915 else
915 { 916 {
917 // If none of the above, maybe it is a simple native shape.
916 if (physicsScene.PE.IsNativeShape(pShape)) 918 if (physicsScene.PE.IsNativeShape(pShape))
917 { 919 {
918 BSShapeNative nativeShape = new BSShapeNative(pShape); 920 BSShapeNative nativeShape = new BSShapeNative(pShape);
@@ -1052,6 +1054,7 @@ public class BSShapeGImpact : BSShape
1052 1054
1053 // Check to see if mesh was created (might require an asset). 1055 // Check to see if mesh was created (might require an asset).
1054 newShape = VerifyMeshCreated(physicsScene, newShape, prim); 1056 newShape = VerifyMeshCreated(physicsScene, newShape, prim);
1057 newShape.shapeKey = newMeshKey;
1055 if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed) 1058 if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed)
1056 { 1059 {
1057 // If a mesh was what was created, remember the built shape for later sharing. 1060 // If a mesh was what was created, remember the built shape for later sharing.