diff options
Diffstat (limited to '')
6 files changed, 80 insertions, 101 deletions
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/IMapTileTerrainRenderer.cs b/OpenSim/Region/CoreModules/World/WorldMap/IMapTileTerrainRenderer.cs index 3684df0..eaf43d3 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/IMapTileTerrainRenderer.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/IMapTileTerrainRenderer.cs | |||
@@ -25,10 +25,10 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System.Drawing; | 28 | using System.Drawing; |
29 | using OpenSim.Region.Framework.Scenes; | 29 | using Nini.Config; |
30 | using Nini.Config; | 30 | using OpenSim.Region.Framework.Scenes; |
31 | 31 | ||
32 | namespace OpenSim.Region.CoreModules.World.WorldMap | 32 | namespace OpenSim.Region.CoreModules.World.WorldMap |
33 | { | 33 | { |
34 | public interface IMapTileTerrainRenderer | 34 | public interface IMapTileTerrainRenderer |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/MapImageModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/MapImageModule.cs index eea6cf6..188915d 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/MapImageModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/MapImageModule.cs | |||
@@ -25,20 +25,17 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Collections; | 29 | using System.Collections.Generic; |
30 | using System.Collections.Generic; | 30 | using System.Drawing; |
31 | using System.Drawing; | 31 | using System.Reflection; |
32 | using System.Drawing.Drawing2D; | 32 | using log4net; |
33 | using System.Drawing.Imaging; | 33 | using Nini.Config; |
34 | using System.Reflection; | 34 | using OpenMetaverse; |
35 | using Nini.Config; | 35 | using OpenMetaverse.Imaging; |
36 | using OpenMetaverse.Imaging; | 36 | using OpenSim.Region.Framework.Interfaces; |
37 | using log4net; | 37 | using OpenSim.Region.Framework.Scenes; |
38 | using OpenSim.Region.Framework.Interfaces; | 38 | |
39 | using OpenSim.Region.Framework.Scenes; | ||
40 | using OpenMetaverse; | ||
41 | |||
42 | namespace OpenSim.Region.CoreModules.World.WorldMap | 39 | namespace OpenSim.Region.CoreModules.World.WorldMap |
43 | { | 40 | { |
44 | public enum DrawRoutine | 41 | public enum DrawRoutine |
@@ -208,7 +205,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
208 | { | 205 | { |
209 | int tc = 0; | 206 | int tc = 0; |
210 | double[,] hm = whichScene.Heightmap.GetDoubles(); | 207 | double[,] hm = whichScene.Heightmap.GetDoubles(); |
211 | tc = System.Environment.TickCount; | 208 | tc = Environment.TickCount; |
212 | m_log.Info("[MAPTILE]: Generating Maptile Step 2: Object Volume Profile"); | 209 | m_log.Info("[MAPTILE]: Generating Maptile Step 2: Object Volume Profile"); |
213 | List<EntityBase> objs = whichScene.GetEntities(); | 210 | List<EntityBase> objs = whichScene.GetEntities(); |
214 | Dictionary<uint, DrawStruct> z_sort = new Dictionary<uint, DrawStruct>(); | 211 | Dictionary<uint, DrawStruct> z_sort = new Dictionary<uint, DrawStruct>(); |
@@ -525,7 +522,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
525 | g.Dispose(); | 522 | g.Dispose(); |
526 | } // lock entities objs | 523 | } // lock entities objs |
527 | 524 | ||
528 | m_log.Info("[MAPTILE]: Generating Maptile Step 2: Done in " + (System.Environment.TickCount - tc) + " ms"); | 525 | m_log.Info("[MAPTILE]: Generating Maptile Step 2: Done in " + (Environment.TickCount - tc) + " ms"); |
529 | return mapbmp; | 526 | return mapbmp; |
530 | } | 527 | } |
531 | 528 | ||
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs index 45a99a9..bd7e140 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/MapSearchModule.cs | |||
@@ -24,18 +24,16 @@ | |||
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | 24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | using System; | 27 | using System.Collections.Generic; |
28 | using System.Reflection; | 28 | using System.Reflection; |
29 | using System.Collections.Generic; | 29 | using log4net; |
30 | using System.Net; | 30 | using Nini.Config; |
31 | using OpenSim.Framework; | 31 | using OpenMetaverse; |
32 | using OpenSim.Region.Framework.Interfaces; | 32 | using OpenSim.Framework; |
33 | using OpenSim.Region.Framework.Scenes; | 33 | using OpenSim.Region.Framework.Interfaces; |
34 | using OpenSim.Region.Framework.Scenes.Hypergrid; | 34 | using OpenSim.Region.Framework.Scenes; |
35 | using OpenMetaverse; | 35 | using OpenSim.Region.Framework.Scenes.Hypergrid; |
36 | using log4net; | 36 | |
37 | using Nini.Config; | ||
38 | |||
39 | namespace OpenSim.Region.CoreModules.World.WorldMap | 37 | namespace OpenSim.Region.CoreModules.World.WorldMap |
40 | { | 38 | { |
41 | public class MapSearchModule : IRegionModule | 39 | public class MapSearchModule : IRegionModule |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/ShadedMapTileRenderer.cs b/OpenSim/Region/CoreModules/World/WorldMap/ShadedMapTileRenderer.cs index b783d7c..501c826 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/ShadedMapTileRenderer.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/ShadedMapTileRenderer.cs | |||
@@ -25,20 +25,13 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Collections; | 29 | using System.Drawing; |
30 | using System.Collections.Generic; | 30 | using System.Reflection; |
31 | using System.Drawing; | 31 | using log4net; |
32 | using System.Drawing.Drawing2D; | 32 | using Nini.Config; |
33 | using System.Drawing.Imaging; | 33 | using OpenSim.Region.Framework.Scenes; |
34 | using System.Reflection; | 34 | |
35 | using OpenMetaverse; | ||
36 | using OpenMetaverse.Imaging; | ||
37 | using Nini.Config; | ||
38 | using log4net; | ||
39 | using OpenSim.Region.Framework.Interfaces; | ||
40 | using OpenSim.Region.Framework.Scenes; | ||
41 | |||
42 | namespace OpenSim.Region.CoreModules.World.WorldMap | 35 | namespace OpenSim.Region.CoreModules.World.WorldMap |
43 | { | 36 | { |
44 | public class ShadedMapTileRenderer : IMapTileTerrainRenderer | 37 | public class ShadedMapTileRenderer : IMapTileTerrainRenderer |
@@ -57,7 +50,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
57 | 50 | ||
58 | public void TerrainToBitmap(Bitmap mapbmp) | 51 | public void TerrainToBitmap(Bitmap mapbmp) |
59 | { | 52 | { |
60 | int tc = System.Environment.TickCount; | 53 | int tc = Environment.TickCount; |
61 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Terrain"); | 54 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Terrain"); |
62 | 55 | ||
63 | double[,] hm = m_scene.Heightmap.GetDoubles(); | 56 | double[,] hm = m_scene.Heightmap.GetDoubles(); |
@@ -151,7 +144,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
151 | hfdiffihighlight = hfdiffihighlight + Math.Abs((int)(((hfdiff * highlightfactor) % 1f) * 5f) - 1); | 144 | hfdiffihighlight = hfdiffihighlight + Math.Abs((int)(((hfdiff * highlightfactor) % 1f) * 5f) - 1); |
152 | } | 145 | } |
153 | } | 146 | } |
154 | catch (System.OverflowException) | 147 | catch (OverflowException) |
155 | { | 148 | { |
156 | m_log.Debug("[MAPTILE]: Shadow failed at value: " + hfdiff.ToString()); | 149 | m_log.Debug("[MAPTILE]: Shadow failed at value: " + hfdiff.ToString()); |
157 | ShadowDebugContinue = false; | 150 | ShadowDebugContinue = false; |
@@ -199,7 +192,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
199 | } | 192 | } |
200 | } | 193 | } |
201 | } | 194 | } |
202 | catch (System.ArgumentException) | 195 | catch (ArgumentException) |
203 | { | 196 | { |
204 | if (!terraincorruptedwarningsaid) | 197 | if (!terraincorruptedwarningsaid) |
205 | { | 198 | { |
@@ -230,7 +223,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
230 | Color water = Color.FromArgb((int)heightvalue, (int)heightvalue, 255); | 223 | Color water = Color.FromArgb((int)heightvalue, (int)heightvalue, 255); |
231 | mapbmp.SetPixel(x, yr, water); | 224 | mapbmp.SetPixel(x, yr, water); |
232 | } | 225 | } |
233 | catch (System.ArgumentException) | 226 | catch (ArgumentException) |
234 | { | 227 | { |
235 | if (!terraincorruptedwarningsaid) | 228 | if (!terraincorruptedwarningsaid) |
236 | { | 229 | { |
@@ -243,7 +236,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
243 | } | 236 | } |
244 | } | 237 | } |
245 | } | 238 | } |
246 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Done in " + (System.Environment.TickCount - tc) + " ms"); | 239 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Done in " + (Environment.TickCount - tc) + " ms"); |
247 | } | 240 | } |
248 | } | 241 | } |
249 | } | 242 | } |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/TexturedMapTileRenderer.cs b/OpenSim/Region/CoreModules/World/WorldMap/TexturedMapTileRenderer.cs index 537644a..dc59d9e 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/TexturedMapTileRenderer.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/TexturedMapTileRenderer.cs | |||
@@ -25,22 +25,17 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Collections; | 29 | using System.Collections.Generic; |
30 | using System.Collections.Generic; | 30 | using System.Drawing; |
31 | using System.Drawing; | 31 | using System.Reflection; |
32 | using System.Drawing.Drawing2D; | 32 | using log4net; |
33 | using System.Drawing.Imaging; | 33 | using Nini.Config; |
34 | using System.Reflection; | 34 | using OpenMetaverse; |
35 | using OpenMetaverse; | 35 | using OpenMetaverse.Imaging; |
36 | using Nini.Config; | 36 | using OpenSim.Framework; |
37 | using log4net; | 37 | using OpenSim.Region.Framework.Scenes; |
38 | using OpenMetaverse.Imaging; | 38 | |
39 | using OpenSim.Framework; | ||
40 | using OpenSim.Region.Framework.Interfaces; | ||
41 | using OpenSim.Region.Framework.Scenes; | ||
42 | using OpenSim.Region.CoreModules.World.Terrain; | ||
43 | |||
44 | namespace OpenSim.Region.CoreModules.World.WorldMap | 39 | namespace OpenSim.Region.CoreModules.World.WorldMap |
45 | { | 40 | { |
46 | // Hue, Saturation, Value; used for color-interpolation | 41 | // Hue, Saturation, Value; used for color-interpolation |
@@ -269,7 +264,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
269 | 264 | ||
270 | public void TerrainToBitmap(Bitmap mapbmp) | 265 | public void TerrainToBitmap(Bitmap mapbmp) |
271 | { | 266 | { |
272 | int tc = System.Environment.TickCount; | 267 | int tc = Environment.TickCount; |
273 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Terrain"); | 268 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Terrain"); |
274 | 269 | ||
275 | // These textures should be in the AssetCache anyway, as every client conneting to this | 270 | // These textures should be in the AssetCache anyway, as every client conneting to this |
@@ -405,7 +400,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
405 | } | 400 | } |
406 | } | 401 | } |
407 | } | 402 | } |
408 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Done in " + (System.Environment.TickCount - tc) + " ms"); | 403 | m_log.Info("[MAPTILE]: Generating Maptile Step 1: Done in " + (Environment.TickCount - tc) + " ms"); |
409 | } | 404 | } |
410 | } | 405 | } |
411 | } | 406 | } |
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs index 376e365..b372988 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs | |||
@@ -25,33 +25,29 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | 28 | using System; |
29 | using System.Collections; | 29 | using System.Collections; |
30 | using System.Collections.Generic; | 30 | using System.Collections.Generic; |
31 | using System.Drawing; | 31 | using System.Drawing; |
32 | using System.Drawing.Imaging; | 32 | using System.Drawing.Imaging; |
33 | using System.IO; | 33 | using System.IO; |
34 | using System.Net; | 34 | using System.Net; |
35 | using System.Reflection; | 35 | using System.Reflection; |
36 | using System.Threading; | 36 | using System.Threading; |
37 | using OpenMetaverse; | 37 | using log4net; |
38 | using OpenMetaverse.Imaging; | 38 | using Nini.Config; |
39 | using OpenMetaverse.StructuredData; | 39 | using OpenMetaverse; |
40 | using log4net; | 40 | using OpenMetaverse.Imaging; |
41 | using Nini.Config; | 41 | using OpenMetaverse.StructuredData; |
42 | using OpenSim.Framework; | 42 | using OpenSim.Framework; |
43 | using OpenSim.Framework.Communications.Cache; | 43 | using OpenSim.Framework.Communications.Capabilities; |
44 | using OpenSim.Framework.Communications.Capabilities; | 44 | using OpenSim.Framework.Servers; |
45 | using OpenSim.Framework.Servers; | 45 | using OpenSim.Region.Framework.Interfaces; |
46 | using OpenSim.Region.Framework.Interfaces; | 46 | using OpenSim.Region.Framework.Scenes; |
47 | using OpenSim.Region.Framework.Scenes; | 47 | using Caps=OpenSim.Framework.Communications.Capabilities.Caps; |
48 | using OpenSim.Region.Framework.Scenes.Types; | 48 | using OSDArray=OpenMetaverse.StructuredData.OSDArray; |
49 | using Caps = OpenSim.Framework.Communications.Capabilities.Caps; | 49 | using OSDMap=OpenMetaverse.StructuredData.OSDMap; |
50 | 50 | ||
51 | using OSD = OpenMetaverse.StructuredData.OSD; | ||
52 | using OSDMap = OpenMetaverse.StructuredData.OSDMap; | ||
53 | using OSDArray = OpenMetaverse.StructuredData.OSDArray; | ||
54 | |||
55 | namespace OpenSim.Region.CoreModules.World.WorldMap | 51 | namespace OpenSim.Region.CoreModules.World.WorldMap |
56 | { | 52 | { |
57 | public class WorldMapModule : IRegionModule | 53 | public class WorldMapModule : IRegionModule |
@@ -329,7 +325,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
329 | { | 325 | { |
330 | // Local Map Item Request | 326 | // Local Map Item Request |
331 | List<ScenePresence> avatars = m_scene.GetAvatars(); | 327 | List<ScenePresence> avatars = m_scene.GetAvatars(); |
332 | int tc = System.Environment.TickCount; | 328 | int tc = Environment.TickCount; |
333 | List<mapItemReply> mapitems = new List<mapItemReply>(); | 329 | List<mapItemReply> mapitems = new List<mapItemReply>(); |
334 | mapItemReply mapitem = new mapItemReply(); | 330 | mapItemReply mapitem = new mapItemReply(); |
335 | if (avatars.Count == 0 || avatars.Count == 1) | 331 | if (avatars.Count == 0 || avatars.Count == 1) |
@@ -554,7 +550,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
554 | lock (m_blacklistedregions) | 550 | lock (m_blacklistedregions) |
555 | { | 551 | { |
556 | if (!m_blacklistedregions.ContainsKey(regionhandle)) | 552 | if (!m_blacklistedregions.ContainsKey(regionhandle)) |
557 | m_blacklistedregions.Add(regionhandle, System.Environment.TickCount); | 553 | m_blacklistedregions.Add(regionhandle, Environment.TickCount); |
558 | } | 554 | } |
559 | m_log.InfoFormat("[WORLD MAP]: Blacklisted region {0}", regionhandle.ToString()); | 555 | m_log.InfoFormat("[WORLD MAP]: Blacklisted region {0}", regionhandle.ToString()); |
560 | } | 556 | } |
@@ -610,7 +606,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
610 | lock (m_blacklistedurls) | 606 | lock (m_blacklistedurls) |
611 | { | 607 | { |
612 | if (!m_blacklistedurls.ContainsKey(httpserver)) | 608 | if (!m_blacklistedurls.ContainsKey(httpserver)) |
613 | m_blacklistedurls.Add(httpserver, System.Environment.TickCount); | 609 | m_blacklistedurls.Add(httpserver, Environment.TickCount); |
614 | } | 610 | } |
615 | 611 | ||
616 | m_log.WarnFormat("[WORLD MAP]: Blacklisted {0}", httpserver); | 612 | m_log.WarnFormat("[WORLD MAP]: Blacklisted {0}", httpserver); |
@@ -639,7 +635,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
639 | lock (m_blacklistedurls) | 635 | lock (m_blacklistedurls) |
640 | { | 636 | { |
641 | if (!m_blacklistedurls.ContainsKey(httpserver)) | 637 | if (!m_blacklistedurls.ContainsKey(httpserver)) |
642 | m_blacklistedurls.Add(httpserver, System.Environment.TickCount); | 638 | m_blacklistedurls.Add(httpserver, Environment.TickCount); |
643 | } | 639 | } |
644 | 640 | ||
645 | m_log.WarnFormat("[WORLD MAP]: Blacklisted {0}", httpserver); | 641 | m_log.WarnFormat("[WORLD MAP]: Blacklisted {0}", httpserver); |
@@ -804,7 +800,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap | |||
804 | List<ScenePresence> avatars = m_scene.GetAvatars(); | 800 | List<ScenePresence> avatars = m_scene.GetAvatars(); |
805 | OSDArray responsearr = new OSDArray(avatars.Count); | 801 | OSDArray responsearr = new OSDArray(avatars.Count); |
806 | OSDMap responsemapdata = new OSDMap(); | 802 | OSDMap responsemapdata = new OSDMap(); |
807 | int tc = System.Environment.TickCount; | 803 | int tc = Environment.TickCount; |
808 | /* | 804 | /* |
809 | foreach (ScenePresence av in avatars) | 805 | foreach (ScenePresence av in avatars) |
810 | { | 806 | { |