aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorRobert Adams2013-01-28 09:02:01 -0800
committerRobert Adams2013-01-28 09:02:01 -0800
commitf6380a3ad3ee9479886415a117849eb5bd3f40f7 (patch)
tree427f5f385ac238b2acbc0a5b6c0bd33450ea85d3 /OpenSim/Region
parentBulletSim: update Bullet with profiling disabled. This seems to fix the memor... (diff)
downloadopensim-SC_OLD-f6380a3ad3ee9479886415a117849eb5bd3f40f7.zip
opensim-SC_OLD-f6380a3ad3ee9479886415a117849eb5bd3f40f7.tar.gz
opensim-SC_OLD-f6380a3ad3ee9479886415a117849eb5bd3f40f7.tar.bz2
opensim-SC_OLD-f6380a3ad3ee9479886415a117849eb5bd3f40f7.tar.xz
BulletSim: fix the trimming of colliders so only the top 25 are returned.
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/Physics/BulletSPlugin/BSScene.cs4
-rw-r--r--OpenSim/Region/Physics/OdePlugin/OdeScene.cs4
2 files changed, 4 insertions, 4 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
index 86eb773..b23be91 100644
--- a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
@@ -708,8 +708,8 @@ public sealed class BSScene : PhysicsScene, IPhysicsParameters
708 } 708 }
709 709
710 List<BSPhysObject> orderedPrims = new List<BSPhysObject>(PhysObjects.Values); 710 List<BSPhysObject> orderedPrims = new List<BSPhysObject>(PhysObjects.Values);
711 orderedPrims.OrderByDescending(p => p.CollisionScore).Take(25); 711 orderedPrims.OrderByDescending(p => p.CollisionScore);
712 topColliders = orderedPrims.ToDictionary(p => p.LocalID, p => p.CollisionScore); 712 topColliders = orderedPrims.Take(25).ToDictionary(p => p.LocalID, p => p.CollisionScore);
713 } 713 }
714 714
715 return topColliders; 715 return topColliders;
diff --git a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
index 02a0b15..6d7f079 100644
--- a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
+++ b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
@@ -4096,8 +4096,8 @@ namespace OpenSim.Region.Physics.OdePlugin
4096 lock (_prims) 4096 lock (_prims)
4097 { 4097 {
4098 List<OdePrim> orderedPrims = new List<OdePrim>(_prims); 4098 List<OdePrim> orderedPrims = new List<OdePrim>(_prims);
4099 orderedPrims.OrderByDescending(p => p.CollisionScore).Take(25); 4099 orderedPrims.OrderByDescending(p => p.CollisionScore);
4100 topColliders = orderedPrims.ToDictionary(p => p.LocalID, p => p.CollisionScore); 4100 topColliders = orderedPrims.Take(25).ToDictionary(p => p.LocalID, p => p.CollisionScore);
4101 4101
4102 foreach (OdePrim p in _prims) 4102 foreach (OdePrim p in _prims)
4103 p.CollisionScore = 0; 4103 p.CollisionScore = 0;