and some more guard try{}catch{} on ub mesh processing

0.9.1.0-post-fixes
UbitUmarov 2018-07-29 23:31:38 +01:00
parent a6d5da3e7f
commit 390cb703f3
1 changed files with 31 additions and 8 deletions

View File

@ -242,28 +242,51 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing
if (primShape.SculptEntry)
{
if (((OpenMetaverse.SculptType)primShape.SculptType) == SculptType.Mesh)
if (((SculptType)primShape.SculptType) == SculptType.Mesh)
{
if (!useMeshiesPhysicsMesh)
return null;
try
{
if (!GenerateCoordsAndFacesFromPrimMeshData(primName, primShape, out coords, out faces, convex))
return null;
needsConvexProcessing = false;
}
catch
{
m_log.ErrorFormat("[MESH]: fail to process mesh asset for prim {0}", primName);
return null;
}
}
else
{
try
{
if (!GenerateCoordsAndFacesFromPrimSculptData(primName, primShape, lod, out coords, out faces))
return null;
needsConvexProcessing &= doConvexSculpts;
}
catch
{
m_log.ErrorFormat("[MESH]: fail to process sculpt map for prim {0}", primName);
return null;
}
}
}
else
{
try
{
if (!GenerateCoordsAndFacesFromPrimShapeData(primName, primShape, lod, convex, out coords, out faces))
return null;
needsConvexProcessing &= doConvexPrims;
}
catch
{
m_log.ErrorFormat("[MESH]: fail to process shape parameters for prim {0}", primName);
return null;
}
}
int numCoords = coords.Count;
int numFaces = faces.Count;