aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs15
1 files changed, 14 insertions, 1 deletions
diff --git a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs
index 5728731..be328a7 100644
--- a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs
+++ b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs
@@ -631,16 +631,29 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
631 private warp_Texture GetTexture(UUID id) 631 private warp_Texture GetTexture(UUID id)
632 { 632 {
633 warp_Texture ret = null; 633 warp_Texture ret = null;
634
634 byte[] asset = m_scene.AssetService.GetData(id.ToString()); 635 byte[] asset = m_scene.AssetService.GetData(id.ToString());
636
635 if (asset != null) 637 if (asset != null)
636 { 638 {
637 IJ2KDecoder imgDecoder = m_scene.RequestModuleInterface<IJ2KDecoder>(); 639 IJ2KDecoder imgDecoder = m_scene.RequestModuleInterface<IJ2KDecoder>();
638 Bitmap img = (Bitmap) imgDecoder.DecodeToImage(asset); 640 Bitmap img = null;
641
642 try
643 {
644 img = (Bitmap)imgDecoder.DecodeToImage(asset);
645 }
646 catch (Exception e)
647 {
648 m_log.Warn(string.Format("[WARP 3D IMAGE MODULE]: Failed to decode asset {0}, exception ", id), e);
649 }
650
639 if (img != null) 651 if (img != null)
640 { 652 {
641 return new warp_Texture(img); 653 return new warp_Texture(img);
642 } 654 }
643 } 655 }
656
644 return ret; 657 return ret;
645 } 658 }
646 659