diff options
author | Teravus Ovares | 2008-05-22 02:40:19 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-05-22 02:40:19 +0000 |
commit | bdcfc2e3229f8f3370ab81a624c1a8b71e00d8a5 (patch) | |
tree | 259f3b46fe18578abebe07325b3921462d9faf35 | |
parent | * Fix mantis 1325. This is a minor issue where 'show assets' would not work ... (diff) | |
download | opensim-SC_OLD-bdcfc2e3229f8f3370ab81a624c1a8b71e00d8a5.zip opensim-SC_OLD-bdcfc2e3229f8f3370ab81a624c1a8b71e00d8a5.tar.gz opensim-SC_OLD-bdcfc2e3229f8f3370ab81a624c1a8b71e00d8a5.tar.bz2 opensim-SC_OLD-bdcfc2e3229f8f3370ab81a624c1a8b71e00d8a5.tar.xz |
* Prevent an error from stopping startup when decoding the sculpt mesh j2k fails.
-rw-r--r-- | OpenSim/Region/Physics/Meshing/SculptMesh.cs | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/OpenSim/Region/Physics/Meshing/SculptMesh.cs b/OpenSim/Region/Physics/Meshing/SculptMesh.cs index 1c4db15..28a4473 100644 --- a/OpenSim/Region/Physics/Meshing/SculptMesh.cs +++ b/OpenSim/Region/Physics/Meshing/SculptMesh.cs | |||
@@ -52,8 +52,18 @@ namespace OpenSim.Region.Physics.Meshing | |||
52 | { | 52 | { |
53 | if (_lod == 2f || _lod == 4f || _lod == 8f || _lod == 16f || _lod == 32f || _lod == 64f) | 53 | if (_lod == 2f || _lod == 4f || _lod == 8f || _lod == 16f || _lod == 32f || _lod == 64f) |
54 | lod = (int)_lod; | 54 | lod = (int)_lod; |
55 | 55 | ||
56 | idata = OpenJPEG.DecodeToImage(jpegData); | 56 | try |
57 | { | ||
58 | idata = OpenJPEG.DecodeToImage(jpegData); | ||
59 | //int i = 0; | ||
60 | //i = i / i; | ||
61 | } | ||
62 | catch (Exception) | ||
63 | { | ||
64 | System.Console.WriteLine("[PHYSICS]: Unable to generate a Sculpty physics proxy. Sculpty texture decode failed!"); | ||
65 | return; | ||
66 | } | ||
57 | if (idata != null) | 67 | if (idata != null) |
58 | { | 68 | { |
59 | bBitmap = new Bitmap(idata); | 69 | bBitmap = new Bitmap(idata); |