diff options
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs')
-rwxr-xr-x | OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs index f89c52f..2dc029e 100755 --- a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs | |||
@@ -368,9 +368,10 @@ public class BSShapeMesh : BSShape | |||
368 | 368 | ||
369 | // Check to see if mesh was created (might require an asset). | 369 | // Check to see if mesh was created (might require an asset). |
370 | newShape = VerifyMeshCreated(physicsScene, newShape, prim); | 370 | newShape = VerifyMeshCreated(physicsScene, newShape, prim); |
371 | if (!newShape.isNativeShape) | 371 | if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed) |
372 | { | 372 | { |
373 | // If a mesh was what was created, remember the built shape for later sharing. | 373 | // If a mesh was what was created, remember the built shape for later sharing. |
374 | // Also note that if meshing failed we put it in the mesh list as there is nothing else to do about the mesh. | ||
374 | Meshes.Add(newMeshKey, retMesh); | 375 | Meshes.Add(newMeshKey, retMesh); |
375 | } | 376 | } |
376 | 377 | ||
@@ -483,8 +484,11 @@ public class BSShapeMesh : BSShape | |||
483 | } | 484 | } |
484 | else | 485 | else |
485 | { | 486 | { |
487 | // Force the asset condition to 'failed' so we won't try to keep fetching and processing this mesh. | ||
488 | prim.PrimAssetState = BSPhysObject.PrimAssetCondition.Failed; | ||
486 | physicsScene.Logger.DebugFormat("{0} All mesh triangles degenerate. Prim {1} at {2} in {3}", | 489 | physicsScene.Logger.DebugFormat("{0} All mesh triangles degenerate. Prim {1} at {2} in {3}", |
487 | LogHeader, prim.PhysObjectName, prim.RawPosition, physicsScene.Name); | 490 | LogHeader, prim.PhysObjectName, prim.RawPosition, physicsScene.Name); |
491 | physicsScene.DetailLog("{0},BSShapeMesh.CreatePhysicalMesh,allDegenerate,key={1}", prim.LocalID, newMeshKey); | ||
488 | } | 492 | } |
489 | } | 493 | } |
490 | newShape.shapeKey = newMeshKey; | 494 | newShape.shapeKey = newMeshKey; |
@@ -523,7 +527,7 @@ public class BSShapeHull : BSShape | |||
523 | 527 | ||
524 | // Check to see if hull was created (might require an asset). | 528 | // Check to see if hull was created (might require an asset). |
525 | newShape = VerifyMeshCreated(physicsScene, newShape, prim); | 529 | newShape = VerifyMeshCreated(physicsScene, newShape, prim); |
526 | if (!newShape.isNativeShape) | 530 | if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed) |
527 | { | 531 | { |
528 | // If a mesh was what was created, remember the built shape for later sharing. | 532 | // If a mesh was what was created, remember the built shape for later sharing. |
529 | Hulls.Add(newHullKey, retHull); | 533 | Hulls.Add(newHullKey, retHull); |