diff options
author | Aleric Inglewood | 2010-11-03 17:53:55 +0100 |
---|---|---|
committer | McCabe Maxsted | 2010-11-05 14:07:35 -0700 |
commit | 10394290949522474a483e97688a04088fec3baf (patch) | |
tree | 5498b2e762d750b649d721746a9e88aa26dc71dd /linden/indra/newview/hippoLimits.cpp | |
parent | Applied patch by Ansariel Hiller for #675: Keywords update to reflect changes... (diff) | |
download | meta-impy-10394290949522474a483e97688a04088fec3baf.zip meta-impy-10394290949522474a483e97688a04088fec3baf.tar.gz meta-impy-10394290949522474a483e97688a04088fec3baf.tar.bz2 meta-impy-10394290949522474a483e97688a04088fec3baf.tar.xz |
Rename hippo* files to lower case (PART 1 OF 2)
There was a problem with #include "hippolimits.h" because
the file is called hippoLimits.h (with an uppercase L).
After some discussion on IRC it was reluctantly decided that
filenames should be lowercase, as is done for every Linden file.
Moreover, hippolimits.h is about the class HippoLimits, with
uppercase H, so even that doesn't match.
Of course, then we immediately rename all hippo* files to
lowercase.
This patch ONLY renames the file, with no other changes.
This is done in order to make sure that git won't get confused ;).
All other necessary changes will be in the next commit.
Diffstat (limited to 'linden/indra/newview/hippoLimits.cpp')
-rw-r--r-- | linden/indra/newview/hippoLimits.cpp | 224 |
1 files changed, 0 insertions, 224 deletions
diff --git a/linden/indra/newview/hippoLimits.cpp b/linden/indra/newview/hippoLimits.cpp deleted file mode 100644 index a5d6ee6..0000000 --- a/linden/indra/newview/hippoLimits.cpp +++ /dev/null | |||
@@ -1,224 +0,0 @@ | |||
1 | |||
2 | |||
3 | #include "llviewerprecompiledheaders.h" | ||
4 | |||
5 | #include "hippoLimits.h" | ||
6 | |||
7 | #include "hippoGridManager.h" | ||
8 | #include "llviewercontrol.h" | ||
9 | |||
10 | #include <llerror.h> | ||
11 | |||
12 | |||
13 | HippoLimits *gHippoLimits = 0; | ||
14 | |||
15 | |||
16 | HippoLimits::HippoLimits() | ||
17 | : | ||
18 | mMaxAgentGroups(100), | ||
19 | mMaxHeight(10000.0f), | ||
20 | mMinHoleSize(0.05f), | ||
21 | mMaxHollow(0.95f), | ||
22 | mMinPrimScale(0.001f), | ||
23 | mMaxPrimScale(256.0f), | ||
24 | mMaxLinkedPrims(-1) | ||
25 | { | ||
26 | setLimits(); | ||
27 | } | ||
28 | |||
29 | |||
30 | void HippoLimits::setLimits() | ||
31 | { | ||
32 | if (gHippoGridManager->getConnectedGrid()->getPlatform() == HippoGridInfo::PLATFORM_SECONDLIFE) | ||
33 | { | ||
34 | setSecondLifeLimits(); | ||
35 | } | ||
36 | else | ||
37 | { | ||
38 | setOpenSimLimits(); | ||
39 | } | ||
40 | } | ||
41 | |||
42 | |||
43 | void HippoLimits::setOpenSimLimits() | ||
44 | { | ||
45 | mMaxAgentGroups = gHippoGridManager->getConnectedGrid()->getMaxAgentGroups(); | ||
46 | |||
47 | if (mMaxAgentGroups < 0) | ||
48 | mMaxAgentGroups = 50; | ||
49 | |||
50 | mMaxPrimScale = 256.0f; | ||
51 | mMinPrimScale = 0.001f; | ||
52 | mMinPrimXPos = 0; | ||
53 | mMinPrimYPos = 0; | ||
54 | mMinPrimZPos = 0; | ||
55 | mMaxPrimXPos = F32_MAX; | ||
56 | mMaxPrimYPos = F32_MAX; | ||
57 | mMaxPrimZPos = F32_MAX; | ||
58 | mMaxHeight = 10000.0f; | ||
59 | mMaxLinkedPrims = -1; | ||
60 | mMaxPhysLinkedPrims = -1; | ||
61 | mAllowParcelWindLight = TRUE; | ||
62 | mAllowMinimap = TRUE; | ||
63 | mMaxInventoryItemsTransfer = -1; | ||
64 | mRenderName = 2; | ||
65 | mAllowPhysicalPrims = TRUE; | ||
66 | skyUseClassicClouds = TRUE; | ||
67 | mEnableTeenMode = FALSE; | ||
68 | mEnforceMaxBuild = FALSE; | ||
69 | mRenderWater = TRUE; | ||
70 | |||
71 | if (gHippoGridManager->getConnectedGrid()->isRenderCompat()) { | ||
72 | llinfos << "Using rendering compatible OpenSim limits" << llendl; | ||
73 | mMinHoleSize = 0.05f; | ||
74 | mMaxHollow = 0.95f; | ||
75 | } | ||
76 | else | ||
77 | { | ||
78 | llinfos << "Using Hippo OpenSim limits" << llendl; | ||
79 | mMinHoleSize = 0.01f; | ||
80 | mMaxHollow = 0.99f; | ||
81 | } | ||
82 | } | ||
83 | |||
84 | void HippoLimits::setSecondLifeLimits() | ||
85 | { | ||
86 | llinfos << "Using Second Life limits" << llendl; | ||
87 | mMaxAgentGroups = 25; | ||
88 | mMaxPrimScale = 10.0f; | ||
89 | mMinPrimScale = 0.01f; | ||
90 | mMaxHeight = 4096.0f; | ||
91 | mMinHoleSize = 0.05f; | ||
92 | mMaxHollow = 0.95f; | ||
93 | mMaxLinkedPrims = 255; | ||
94 | mMaxPhysLinkedPrims = 32; | ||
95 | mMinPrimXPos = 0; | ||
96 | mMinPrimYPos = 0; | ||
97 | mMinPrimZPos = 0; | ||
98 | mMaxPrimXPos = 256; | ||
99 | mMaxPrimYPos = 256; | ||
100 | mMaxPrimZPos = 4096; | ||
101 | mAllowParcelWindLight = FALSE; | ||
102 | mAllowMinimap = TRUE; | ||
103 | mMaxInventoryItemsTransfer = 42; | ||
104 | mRenderName = 2; | ||
105 | mAllowPhysicalPrims = TRUE; | ||
106 | skyUseClassicClouds = TRUE; | ||
107 | mEnableTeenMode = FALSE; | ||
108 | mEnforceMaxBuild = FALSE; | ||
109 | mRenderWater = TRUE; | ||
110 | } | ||
111 | |||
112 | F32 HippoLimits::getMaxPrimScale() const | ||
113 | { | ||
114 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
115 | { | ||
116 | return FLT_MAX; | ||
117 | } | ||
118 | else | ||
119 | { | ||
120 | return mMaxPrimScale; | ||
121 | } | ||
122 | } | ||
123 | |||
124 | F32 HippoLimits::getMinPrimScale() const | ||
125 | { | ||
126 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
127 | { | ||
128 | return 0; | ||
129 | } | ||
130 | else | ||
131 | { | ||
132 | return mMinPrimScale; | ||
133 | } | ||
134 | } | ||
135 | |||
136 | F32 HippoLimits::getMaxPrimXPos() const | ||
137 | { | ||
138 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
139 | { | ||
140 | return FLT_MAX; | ||
141 | } | ||
142 | else | ||
143 | { | ||
144 | return mMaxPrimXPos; | ||
145 | } | ||
146 | } | ||
147 | |||
148 | F32 HippoLimits::getMaxPrimYPos() const | ||
149 | { | ||
150 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
151 | { | ||
152 | return FLT_MAX; | ||
153 | } | ||
154 | else | ||
155 | { | ||
156 | return mMaxPrimYPos; | ||
157 | } | ||
158 | } | ||
159 | |||
160 | F32 HippoLimits::getMaxPrimZPos() const | ||
161 | { | ||
162 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
163 | { | ||
164 | return FLT_MAX; | ||
165 | } | ||
166 | else | ||
167 | { | ||
168 | return mMaxPrimZPos; | ||
169 | } | ||
170 | } | ||
171 | |||
172 | F32 HippoLimits::getMinPrimXPos() const | ||
173 | { | ||
174 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
175 | { | ||
176 | return FLT_MIN; | ||
177 | } | ||
178 | else | ||
179 | { | ||
180 | return mMinPrimXPos; | ||
181 | } | ||
182 | } | ||
183 | |||
184 | F32 HippoLimits::getMinPrimYPos() const | ||
185 | { | ||
186 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
187 | { | ||
188 | return FLT_MIN; | ||
189 | } | ||
190 | else | ||
191 | { | ||
192 | return mMinPrimYPos; | ||
193 | } | ||
194 | } | ||
195 | |||
196 | F32 HippoLimits::getMinPrimZPos() const | ||
197 | { | ||
198 | if (gSavedSettings.getBOOL("DisableMaxBuildConstraints") && !mEnforceMaxBuild) | ||
199 | { | ||
200 | return FLT_MIN; | ||
201 | } | ||
202 | else | ||
203 | { | ||
204 | return mMinPrimZPos; | ||
205 | } | ||
206 | } | ||
207 | |||
208 | F32 HippoLimits::getMaxDragDistance() const | ||
209 | { | ||
210 | if (mMaxDragDistance == 0) | ||
211 | { | ||
212 | return FLT_MAX; | ||
213 | } | ||
214 | else | ||
215 | { | ||
216 | F32 max_drag_distance = gSavedSettings.getBOOL("LimitDragDistance") ? gSavedSettings.getF32("MaxDragDistance") : FLT_MAX; | ||
217 | |||
218 | if(max_drag_distance > mMaxDragDistance) //Chose the more restrictive | ||
219 | { | ||
220 | max_drag_distance = mMaxDragDistance; | ||
221 | } | ||
222 | return max_drag_distance; | ||
223 | } | ||
224 | } \ No newline at end of file | ||