diff options
author | Teravus Ovares | 2008-06-19 17:21:17 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-06-19 17:21:17 +0000 |
commit | 1d91613679bd8471051818e2acede4786d08ab4f (patch) | |
tree | 33c62945a22e8e2f43f46d9a8cd8998515b17c3f /OpenSim/Region/Physics | |
parent | * Temporary workaround for mantis 1568. If the avatar apperance factory now ... (diff) | |
download | opensim-SC-1d91613679bd8471051818e2acede4786d08ab4f.zip opensim-SC-1d91613679bd8471051818e2acede4786d08ab4f.tar.gz opensim-SC-1d91613679bd8471051818e2acede4786d08ab4f.tar.bz2 opensim-SC-1d91613679bd8471051818e2acede4786d08ab4f.tar.xz |
* Patch from Dahlia - 0001576: Exception of type 'System.OutOfMemoryException' was thrown .Void set_Capacity(Int32), with regards to sphere mesh. Thanks Dahlia!
* Also allows a sphere to be hollow with no cuts or dimples. (walking around inside the sphere).
Diffstat (limited to 'OpenSim/Region/Physics')
-rw-r--r-- | OpenSim/Region/Physics/Meshing/Meshmerizer.cs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs index dfcf99a..bf6b70c 100644 --- a/OpenSim/Region/Physics/Meshing/Meshmerizer.cs +++ b/OpenSim/Region/Physics/Meshing/Meshmerizer.cs | |||
@@ -1500,6 +1500,7 @@ namespace OpenSim.Region.Physics.Meshing | |||
1500 | && primShape.PathTwistBegin == 0 | 1500 | && primShape.PathTwistBegin == 0 |
1501 | && primShape.ProfileBegin == 0 | 1501 | && primShape.ProfileBegin == 0 |
1502 | && primShape.ProfileEnd == 0 | 1502 | && primShape.ProfileEnd == 0 |
1503 | && primShape.ProfileHollow == 0 | ||
1503 | ) // simple sphere, revert to geodesic shape | 1504 | ) // simple sphere, revert to geodesic shape |
1504 | 1505 | ||
1505 | ) | 1506 | ) |
@@ -1547,6 +1548,9 @@ namespace OpenSim.Region.Physics.Meshing | |||
1547 | fProfileEndAngle = 180.0f - 0.0036f * (float)primShape.ProfileEnd; | 1548 | fProfileEndAngle = 180.0f - 0.0036f * (float)primShape.ProfileEnd; |
1548 | if (fProfileBeginAngle < fProfileEndAngle) | 1549 | if (fProfileBeginAngle < fProfileEndAngle) |
1549 | fProfileEndAngle -= 360.0f; | 1550 | fProfileEndAngle -= 360.0f; |
1551 | // a cut starting at 0 degrees with a hollow causes an infinite loop so move the start angle | ||
1552 | // past it into the empty part of the circle to avoid this condition | ||
1553 | if (fProfileBeginAngle == 0.0f) fProfileBeginAngle = -10.0f; | ||
1550 | 1554 | ||
1551 | #if SPAM | 1555 | #if SPAM |
1552 | Console.WriteLine("Sphere dimple: fProfileBeginAngle: " + fProfileBeginAngle.ToString() + " fProfileEndAngle: " + fProfileEndAngle.ToString()); | 1556 | Console.WriteLine("Sphere dimple: fProfileBeginAngle: " + fProfileBeginAngle.ToString() + " fProfileEndAngle: " + fProfileEndAngle.ToString()); |