From 8ff1bc5b03adfc11903dfdc244e6fe26f07b4bd2 Mon Sep 17 00:00:00 2001 From: Justin Clarke Casey Date: Thu, 18 Sep 2008 18:54:42 +0000 Subject: * Make the ode simulation update loop print out the stack if an exception occurs (at least, this is what will happen on linux) --- OpenSim/Region/Physics/Meshing/Mesh.cs | 4 ---- OpenSim/Region/Physics/Meshing/Meshmerizer.cs | 5 ++--- OpenSim/Region/Physics/Meshing/SculptMesh.cs | 8 +++++--- OpenSim/Region/Physics/OdePlugin/OdePlugin.cs | 2 +- 4 files changed, 8 insertions(+), 11 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/Physics/Meshing/Mesh.cs b/OpenSim/Region/Physics/Meshing/Mesh.cs index 2084e75..06131a7 100644 --- a/OpenSim/Region/Physics/Meshing/Mesh.cs +++ b/OpenSim/Region/Physics/Meshing/Mesh.cs @@ -74,7 +74,6 @@ namespace OpenSim.Region.Physics.Meshing return result; } - public void Add(Triangle triangle) { int i; @@ -135,7 +134,6 @@ namespace OpenSim.Region.Physics.Meshing } } - public void Add(List lv) { foreach (Vertex v in lv) @@ -243,7 +241,6 @@ namespace OpenSim.Region.Physics.Meshing { pinnedVirtexes.Free(); pinnedIndex.Free(); - } /// @@ -256,7 +253,6 @@ namespace OpenSim.Region.Physics.Meshing primMesh = null; } - public void Append(Mesh newMesh) { foreach (Vertex v in newMesh.vertices) diff --git a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs index 6a6d3e2..f64a92d 100644 --- a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs +++ b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs @@ -466,10 +466,10 @@ namespace OpenSim.Region.Physics.Meshing // Deal with cuts now if ((profileBegin != 0) || (profileEnd != 0)) { - double fProfileBeginAngle = profileBegin/50000.0*360.0; + double fProfileBeginAngle = profileBegin / 50000.0*360.0; // In degree, for easier debugging and understanding fProfileBeginAngle -= (90.0 + 45.0); // for some reasons, the SL client counts from the corner -X/-Y - double fProfileEndAngle = 360.0 - profileEnd/50000.0*360.0; // Pathend comes as complement to 1.0 + double fProfileEndAngle = 360.0 - profileEnd / 50000.0*360.0; // Pathend comes as complement to 1.0 fProfileEndAngle -= (90.0 + 45.0); // avoid some problem angles until the hull subtraction routine is fixed @@ -2024,7 +2024,6 @@ namespace OpenSim.Region.Physics.Meshing if (primShape.SculptEntry && primShape.SculptType != (byte)0 && primShape.SculptData.Length > 0) { - SculptMesh smesh = CreateSculptMesh(primName, primShape, size, lod); mesh = (Mesh)smesh; //CalcNormals(mesh); diff --git a/OpenSim/Region/Physics/Meshing/SculptMesh.cs b/OpenSim/Region/Physics/Meshing/SculptMesh.cs index d4bd65f..0f12739 100644 --- a/OpenSim/Region/Physics/Meshing/SculptMesh.cs +++ b/OpenSim/Region/Physics/Meshing/SculptMesh.cs @@ -81,9 +81,8 @@ namespace OpenSim.Region.Physics.Meshing idata.Dispose(); } } - - } + private Vertex ColorToVertex(Color input) { return new Vertex( @@ -91,6 +90,7 @@ namespace OpenSim.Region.Physics.Meshing ((float)input.G - 128) / RANGE, ((float)input.B - 128) / RANGE); } + private void LoadPoles() { northpole = new Vertex(0, 0, 0); @@ -144,6 +144,7 @@ namespace OpenSim.Region.Physics.Meshing return lod; } } + private void DoLOD() { int x_max = Math.Min(Scale, bBitmap.Width); @@ -199,13 +200,14 @@ namespace OpenSim.Region.Physics.Meshing } } + public void clearStuff() { this.triangles.Clear(); this.vertices.Clear(); //normals = new float[0]; - } + public void processSculptTexture() { int x_max = Math.Min(Scale, bBitmap.Width); diff --git a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs index 5a501ef..245c757 100644 --- a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs +++ b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs @@ -1732,7 +1732,7 @@ namespace OpenSim.Region.Physics.OdePlugin } catch (Exception e) { - m_log.Error("[PHYSICS]: " + e.Message.ToString() + e.TargetSite.ToString()); + m_log.ErrorFormat("[PHYSICS]: {0}, {1}, {2}", e.Message, e.TargetSite, e); ode.dunlock(world); } -- cgit v1.1