aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/Linden/UDP
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden/UDP')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs14
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLImageManager.cs10
2 files changed, 19 insertions, 5 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index eb1a50e..1e72aa2 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -304,6 +304,11 @@ namespace OpenSim.Region.ClientStack.LindenUDP
304 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 304 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
305 protected static Dictionary<PacketType, PacketMethod> PacketHandlers = new Dictionary<PacketType, PacketMethod>(); //Global/static handlers for all clients 305 protected static Dictionary<PacketType, PacketMethod> PacketHandlers = new Dictionary<PacketType, PacketMethod>(); //Global/static handlers for all clients
306 306
307 /// <summary>
308 /// Handles UDP texture download.
309 /// </summary>
310 public LLImageManager ImageManager { get; private set; }
311
307 private readonly LLUDPServer m_udpServer; 312 private readonly LLUDPServer m_udpServer;
308 private readonly LLUDPClient m_udpClient; 313 private readonly LLUDPClient m_udpClient;
309 private readonly UUID m_sessionId; 314 private readonly UUID m_sessionId;
@@ -348,7 +353,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
348 protected Dictionary<PacketType, PacketProcessor> m_packetHandlers = new Dictionary<PacketType, PacketProcessor>(); 353 protected Dictionary<PacketType, PacketProcessor> m_packetHandlers = new Dictionary<PacketType, PacketProcessor>();
349 protected Dictionary<string, GenericMessage> m_genericPacketHandlers = new Dictionary<string, GenericMessage>(); //PauPaw:Local Generic Message handlers 354 protected Dictionary<string, GenericMessage> m_genericPacketHandlers = new Dictionary<string, GenericMessage>(); //PauPaw:Local Generic Message handlers
350 protected Scene m_scene; 355 protected Scene m_scene;
351 private LLImageManager m_imageManager;
352 protected string m_firstName; 356 protected string m_firstName;
353 protected string m_lastName; 357 protected string m_lastName;
354 protected Thread m_clientThread; 358 protected Thread m_clientThread;
@@ -459,7 +463,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
459 463
460 m_assetService = m_scene.RequestModuleInterface<IAssetService>(); 464 m_assetService = m_scene.RequestModuleInterface<IAssetService>();
461 m_GroupsModule = scene.RequestModuleInterface<IGroupsModule>(); 465 m_GroupsModule = scene.RequestModuleInterface<IGroupsModule>();
462 m_imageManager = new LLImageManager(this, m_assetService, Scene.RequestModuleInterface<IJ2KDecoder>()); 466 ImageManager = new LLImageManager(this, m_assetService, Scene.RequestModuleInterface<IJ2KDecoder>());
463 m_channelVersion = Util.StringToBytes256(scene.GetSimulatorVersion()); 467 m_channelVersion = Util.StringToBytes256(scene.GetSimulatorVersion());
464 m_agentId = agentId; 468 m_agentId = agentId;
465 m_sessionId = sessionId; 469 m_sessionId = sessionId;
@@ -499,7 +503,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
499 IsActive = false; 503 IsActive = false;
500 504
501 // Shutdown the image manager 505 // Shutdown the image manager
502 m_imageManager.Close(); 506 ImageManager.Close();
503 507
504 // Fire the callback for this connection closing 508 // Fire the callback for this connection closing
505 if (OnConnectionClosed != null) 509 if (OnConnectionClosed != null)
@@ -3939,7 +3943,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
3939 } 3943 }
3940 3944
3941 if ((categories & ThrottleOutPacketTypeFlags.Texture) != 0) 3945 if ((categories & ThrottleOutPacketTypeFlags.Texture) != 0)
3942 m_imageManager.ProcessImageQueue(m_udpServer.TextureSendLimit); 3946 ImageManager.ProcessImageQueue(m_udpServer.TextureSendLimit);
3943 } 3947 }
3944 3948
3945 public void SendAssetUploadCompleteMessage(sbyte AssetType, bool Success, UUID AssetFullID) 3949 public void SendAssetUploadCompleteMessage(sbyte AssetType, bool Success, UUID AssetFullID)
@@ -7470,7 +7474,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
7470 if ((ImageType)block.Type == ImageType.Baked) 7474 if ((ImageType)block.Type == ImageType.Baked)
7471 args.Priority *= 2.0f; 7475 args.Priority *= 2.0f;
7472 7476
7473 m_imageManager.EnqueueReq(args); 7477 ImageManager.EnqueueReq(args);
7474 } 7478 }
7475 7479
7476 return true; 7480 return true;
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLImageManager.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLImageManager.cs
index 3e31b7d..db428f1 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLImageManager.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLImageManager.cs
@@ -245,6 +245,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP
245 m_shuttingdown = true; 245 m_shuttingdown = true;
246 } 246 }
247 247
248 /// <summary>
249 /// Returns an array containing all the images in the queue.
250 /// </summary>
251 /// <returns></returns>
252 public J2KImage[] GetImages()
253 {
254 lock (m_priorityQueue)
255 return m_priorityQueue.ToArray();
256 }
257
248 #region Priority Queue Helpers 258 #region Priority Queue Helpers
249 259
250 private J2KImage GetHighestPriorityImage() 260 private J2KImage GetHighestPriorityImage()