aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/hippoLimits.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/hippoLimits.cpp54
1 files changed, 54 insertions, 0 deletions
diff --git a/linden/indra/newview/hippoLimits.cpp b/linden/indra/newview/hippoLimits.cpp
new file mode 100644
index 0000000..63a5899
--- /dev/null
+++ b/linden/indra/newview/hippoLimits.cpp
@@ -0,0 +1,54 @@
1
2
3#include "hippoLimits.h"
4
5#include "hippoGridManager.h"
6
7#include <llerror.h>
8
9
10HippoLimits *gHippoLimits = 0;
11
12
13HippoLimits::HippoLimits()
14{
15 setLimits();
16}
17
18
19void HippoLimits::setLimits()
20{
21 if (gHippoGridManager->getConnectedGrid()->getPlatform() == HippoGridInfo::PLATFORM_SECONDLIFE) {
22 setSecondLifeLimits();
23 } else {
24 setOpenSimLimits();
25 }
26}
27
28
29void HippoLimits::setOpenSimLimits()
30{
31 mMaxAgentGroups = 100;
32 mMaxPrimScale = 256.0f;
33 mMaxHeight = 10000.0f;
34 if (gHippoGridManager->getConnectedGrid()->isRenderCompat()) {
35 llinfos << "Using rendering compatible OpenSim limits." << llendl;
36 mMinHoleSize = 0.05f;
37 mMaxHollow = 0.95f;
38 } else {
39 llinfos << "Using Hippo OpenSim limits." << llendl;
40 mMinHoleSize = 0.01f;
41 mMaxHollow = 0.99f;
42 }
43}
44
45void HippoLimits::setSecondLifeLimits()
46{
47 llinfos << "Using Second Life limits." << llendl;
48 mMaxAgentGroups = 25;
49 mMaxPrimScale = 10.0f;
50 mMaxHeight = 4096.0f;
51 mMinHoleSize = 0.05f;
52 mMaxHollow = 0.95f;
53}
54