diff options
author | Justin Clarke Casey | 2008-07-02 17:35:33 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-07-02 17:35:33 +0000 |
commit | 79f937612ee0544324fff1a04762b4e86136a29f (patch) | |
tree | 06bf874d20abda488b982ef3d587cdbfdd261418 /OpenSim/Region/Environment/Modules/World | |
parent | Adds experimental Meshmerizer support for "prim torture" effects of sphere di... (diff) | |
download | opensim-SC_OLD-79f937612ee0544324fff1a04762b4e86136a29f.zip opensim-SC_OLD-79f937612ee0544324fff1a04762b4e86136a29f.tar.gz opensim-SC_OLD-79f937612ee0544324fff1a04762b4e86136a29f.tar.bz2 opensim-SC_OLD-79f937612ee0544324fff1a04762b4e86136a29f.tar.xz |
* Twiddle with archive asset extensions yet again
* Reintroducing asset type but this time in a long form, and with _ rather than .
Diffstat (limited to 'OpenSim/Region/Environment/Modules/World')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Archiver/ArchiveConstants.cs | 88 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Archiver/ArchiveReadRequest.cs | 2 |
2 files changed, 45 insertions, 45 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveConstants.cs b/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveConstants.cs index 7b76cb8..22d1ed7d 100644 --- a/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveConstants.cs +++ b/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveConstants.cs | |||
@@ -63,59 +63,59 @@ namespace OpenSim.Region.Environment.Modules.World.Archiver | |||
63 | 63 | ||
64 | static ArchiveConstants() | 64 | static ArchiveConstants() |
65 | { | 65 | { |
66 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Animation] = ".bvh"; | 66 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Animation] = "_animation.bvh"; |
67 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Bodypart] = ".bpt"; | 67 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Bodypart] = "_bodypart.txt"; |
68 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.CallingCard] = ".ccd"; | 68 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.CallingCard] = "_callingcard.txt"; |
69 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Clothing] = ".clo"; | 69 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Clothing] = "_clothing.txt"; |
70 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Folder] = ".fld"; // Not sure if we'll ever see this | 70 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Folder] = "_folder.txt"; // Not sure if we'll ever see this |
71 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Gesture] = ".gst"; | 71 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Gesture] = "_gesture.txt"; |
72 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.ImageJPEG] = ".jpg"; | 72 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.ImageJPEG] = "_image.jpg"; |
73 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.ImageTGA] = ".imgtga"; | 73 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.ImageTGA] = "_image.tga"; |
74 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LostAndFoundFolder] = ".lfd"; // Not sure if we'll ever see this | 74 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LostAndFoundFolder] = "_lostandfoundfolder.txt"; // Not sure if we'll ever see this |
75 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LSLBytecode] = ".lso"; | 75 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LSLBytecode] = "_bytecode.lso"; |
76 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LSLText] = ".lsl"; | 76 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.LSLText] = "_script.lsl"; |
77 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Notecard] = ".ncd"; | 77 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Notecard] = "_notecard.txt"; |
78 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Object] = ".oob"; | 78 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Object] = "_object.xml"; |
79 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.RootFolder] = ".rfd"; // Not sure if we'll ever see this | 79 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.RootFolder] = "_rootfolder.txt"; // Not sure if we'll ever see this |
80 | // disable warning: we know Script is obsolete, but need to support it | 80 | // disable warning: we know Script is obsolete, but need to support it |
81 | // anyhow | 81 | // anyhow |
82 | #pragma warning disable 0612 | 82 | #pragma warning disable 0612 |
83 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Script] = ".spt"; // Not sure if we'll ever see this | 83 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Script] = "_script.txt"; // Not sure if we'll ever see this |
84 | #pragma warning restore 0612 | 84 | #pragma warning restore 0612 |
85 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Simstate] = ".sst"; // Not sure if we'll ever see this | 85 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Simstate] = "_simstate.bin"; // Not sure if we'll ever see this |
86 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.SnapshotFolder] = ".sfd"; // Not sure if we'll ever see this | 86 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.SnapshotFolder] = "_snapshotfolder.txt"; // Not sure if we'll ever see this |
87 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Sound] = ".ogg"; | 87 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Sound] = "_sound.ogg"; |
88 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.SoundWAV] = ".wav"; | 88 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.SoundWAV] = "_sound.wav"; |
89 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Texture] = ".jp2"; | 89 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.Texture] = "_texture.jp2"; |
90 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.TextureTGA] = ".tga"; | 90 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.TextureTGA] = "_texture.tga"; |
91 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.TrashFolder] = ".tfd"; // Not sure if we'll ever see this | 91 | ASSET_TYPE_TO_EXTENSION[(sbyte)AssetType.TrashFolder] = "_trashfolder.txt"; // Not sure if we'll ever see this |
92 | 92 | ||
93 | EXTENSION_TO_ASSET_TYPE[".bvh"] = (sbyte)AssetType.Animation; | 93 | EXTENSION_TO_ASSET_TYPE["_animation.bvh"] = (sbyte)AssetType.Animation; |
94 | EXTENSION_TO_ASSET_TYPE[".bpt"] = (sbyte)AssetType.Bodypart; | 94 | EXTENSION_TO_ASSET_TYPE["_bodypart.txt"] = (sbyte)AssetType.Bodypart; |
95 | EXTENSION_TO_ASSET_TYPE[".ccd"] = (sbyte)AssetType.CallingCard; | 95 | EXTENSION_TO_ASSET_TYPE["_callingcard.txt"] = (sbyte)AssetType.CallingCard; |
96 | EXTENSION_TO_ASSET_TYPE[".clo"] = (sbyte)AssetType.Clothing; | 96 | EXTENSION_TO_ASSET_TYPE["_clothing.txt"] = (sbyte)AssetType.Clothing; |
97 | EXTENSION_TO_ASSET_TYPE[".fld"] = (sbyte)AssetType.Folder; | 97 | EXTENSION_TO_ASSET_TYPE["_folder.txt"] = (sbyte)AssetType.Folder; |
98 | EXTENSION_TO_ASSET_TYPE[".gst"] = (sbyte)AssetType.Gesture; | 98 | EXTENSION_TO_ASSET_TYPE["_gesture.txt"] = (sbyte)AssetType.Gesture; |
99 | EXTENSION_TO_ASSET_TYPE[".jpg"] = (sbyte)AssetType.ImageJPEG; | 99 | EXTENSION_TO_ASSET_TYPE["_image.jpg"] = (sbyte)AssetType.ImageJPEG; |
100 | EXTENSION_TO_ASSET_TYPE[".imgtga"] = (sbyte)AssetType.ImageTGA; | 100 | EXTENSION_TO_ASSET_TYPE["_image.tga"] = (sbyte)AssetType.ImageTGA; |
101 | EXTENSION_TO_ASSET_TYPE[".lfd"] = (sbyte)AssetType.LostAndFoundFolder; | 101 | EXTENSION_TO_ASSET_TYPE["_lostandfoundfolder.txt"] = (sbyte)AssetType.LostAndFoundFolder; |
102 | EXTENSION_TO_ASSET_TYPE[".lso"] = (sbyte)AssetType.LSLBytecode; | 102 | EXTENSION_TO_ASSET_TYPE["_bytecode.lso"] = (sbyte)AssetType.LSLBytecode; |
103 | EXTENSION_TO_ASSET_TYPE[".lsl"] = (sbyte)AssetType.LSLText; | 103 | EXTENSION_TO_ASSET_TYPE["_script.lsl"] = (sbyte)AssetType.LSLText; |
104 | EXTENSION_TO_ASSET_TYPE[".ncd"] = (sbyte)AssetType.Notecard; | 104 | EXTENSION_TO_ASSET_TYPE["_notecard.txt"] = (sbyte)AssetType.Notecard; |
105 | EXTENSION_TO_ASSET_TYPE[".oob"] = (sbyte)AssetType.Object; | 105 | EXTENSION_TO_ASSET_TYPE["_object.xml"] = (sbyte)AssetType.Object; |
106 | EXTENSION_TO_ASSET_TYPE[".rfd"] = (sbyte)AssetType.RootFolder; | 106 | EXTENSION_TO_ASSET_TYPE["_rootfolder.txt"] = (sbyte)AssetType.RootFolder; |
107 | // disable warning: we know Script is obsolete, but need to support it | 107 | // disable warning: we know Script is obsolete, but need to support it |
108 | // anyhow | 108 | // anyhow |
109 | #pragma warning disable 0612 | 109 | #pragma warning disable 0612 |
110 | EXTENSION_TO_ASSET_TYPE[".spt"] = (sbyte)AssetType.Script; | 110 | EXTENSION_TO_ASSET_TYPE["_script.txt"] = (sbyte)AssetType.Script; |
111 | #pragma warning restore 0612 | 111 | #pragma warning restore 0612 |
112 | EXTENSION_TO_ASSET_TYPE[".sst"] = (sbyte)AssetType.Simstate; | 112 | EXTENSION_TO_ASSET_TYPE["_simstate.bin"] = (sbyte)AssetType.Simstate; |
113 | EXTENSION_TO_ASSET_TYPE[".sfd"] = (sbyte)AssetType.SnapshotFolder; | 113 | EXTENSION_TO_ASSET_TYPE["_snapshotfolder.txt"] = (sbyte)AssetType.SnapshotFolder; |
114 | EXTENSION_TO_ASSET_TYPE[".ogg"] = (sbyte)AssetType.Sound; | 114 | EXTENSION_TO_ASSET_TYPE["_sound.ogg"] = (sbyte)AssetType.Sound; |
115 | EXTENSION_TO_ASSET_TYPE[".wav"] = (sbyte)AssetType.SoundWAV; | 115 | EXTENSION_TO_ASSET_TYPE["_sound.wav"] = (sbyte)AssetType.SoundWAV; |
116 | EXTENSION_TO_ASSET_TYPE[".jp2"] = (sbyte)AssetType.Texture; | 116 | EXTENSION_TO_ASSET_TYPE["_texture.jp2"] = (sbyte)AssetType.Texture; |
117 | EXTENSION_TO_ASSET_TYPE[".tga"] = (sbyte)AssetType.TextureTGA; | 117 | EXTENSION_TO_ASSET_TYPE["_texture.tga"] = (sbyte)AssetType.TextureTGA; |
118 | EXTENSION_TO_ASSET_TYPE[".tfd"] = (sbyte)AssetType.TrashFolder; | 118 | EXTENSION_TO_ASSET_TYPE["_trashfolder.txt"] = (sbyte)AssetType.TrashFolder; |
119 | } | 119 | } |
120 | } | 120 | } |
121 | } | 121 | } |
diff --git a/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveReadRequest.cs b/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveReadRequest.cs index 610adfb..15bc265 100644 --- a/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveReadRequest.cs +++ b/OpenSim/Region/Environment/Modules/World/Archiver/ArchiveReadRequest.cs | |||
@@ -119,7 +119,7 @@ namespace OpenSim.Region.Environment.Modules.World.Archiver | |||
119 | { | 119 | { |
120 | // Right now we're nastily obtaining the lluuid from the filename | 120 | // Right now we're nastily obtaining the lluuid from the filename |
121 | string filename = assetPath.Remove(0, ArchiveConstants.ASSETS_PATH.Length); | 121 | string filename = assetPath.Remove(0, ArchiveConstants.ASSETS_PATH.Length); |
122 | string extension = filename.Substring(filename.LastIndexOf(".")); | 122 | string extension = filename.Substring(filename.LastIndexOf("_")); |
123 | string uuid = filename.Remove(filename.Length - extension.Length); | 123 | string uuid = filename.Remove(filename.Length - extension.Length); |
124 | 124 | ||
125 | if (ArchiveConstants.EXTENSION_TO_ASSET_TYPE.ContainsKey(extension)) | 125 | if (ArchiveConstants.EXTENSION_TO_ASSET_TYPE.ContainsKey(extension)) |