aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules/Scripting/DynamicTexture
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Modules/Scripting/DynamicTexture')
-rw-r--r--OpenSim/Region/Environment/Modules/Scripting/DynamicTexture/DynamicTextureModule.cs11
1 files changed, 9 insertions, 2 deletions
diff --git a/OpenSim/Region/Environment/Modules/Scripting/DynamicTexture/DynamicTextureModule.cs b/OpenSim/Region/Environment/Modules/Scripting/DynamicTexture/DynamicTextureModule.cs
index c0e3d3b..c22d1c6 100644
--- a/OpenSim/Region/Environment/Modules/Scripting/DynamicTexture/DynamicTextureModule.cs
+++ b/OpenSim/Region/Environment/Modules/Scripting/DynamicTexture/DynamicTextureModule.cs
@@ -57,6 +57,11 @@ namespace OpenSim.Region.Environment.Modules.Scripting.DynamicTexture
57 } 57 }
58 } 58 }
59 59
60 /// <summary>
61 /// Called by code which actually renders the dynamic texture to supply texture data.
62 /// </summary>
63 /// <param name="id"></param>
64 /// <param name="data"></param>
60 public void ReturnData(LLUUID id, byte[] data) 65 public void ReturnData(LLUUID id, byte[] data)
61 { 66 {
62 if (Updaters.ContainsKey(id)) 67 if (Updaters.ContainsKey(id))
@@ -70,7 +75,6 @@ namespace OpenSim.Region.Environment.Modules.Scripting.DynamicTexture
70 } 75 }
71 } 76 }
72 77
73
74 public LLUUID AddDynamicTextureURL(LLUUID simID, LLUUID primID, string contentType, string url, 78 public LLUUID AddDynamicTextureURL(LLUUID simID, LLUUID primID, string contentType, string url,
75 string extraParams, int updateTimer) 79 string extraParams, int updateTimer)
76 { 80 {
@@ -196,11 +200,15 @@ namespace OpenSim.Region.Environment.Modules.Scripting.DynamicTexture
196 BodyData = null; 200 BodyData = null;
197 } 201 }
198 202
203 /// <summary>
204 /// Called once new texture data has been received for this updater.
205 /// </summary>
199 public void DataReceived(byte[] data, Scene scene) 206 public void DataReceived(byte[] data, Scene scene)
200 { 207 {
201 SceneObjectPart part = scene.GetSceneObjectPart(PrimID); 208 SceneObjectPart part = scene.GetSceneObjectPart(PrimID);
202 byte[] assetData; 209 byte[] assetData;
203 AssetBase oldAsset = null; 210 AssetBase oldAsset = null;
211
204 if (BlendWithOldTexture) 212 if (BlendWithOldTexture)
205 { 213 {
206 LLUUID lastTextureID = part.Shape.Textures.DefaultTexture.TextureID; 214 LLUUID lastTextureID = part.Shape.Textures.DefaultTexture.TextureID;
@@ -234,7 +242,6 @@ namespace OpenSim.Region.Environment.Modules.Scripting.DynamicTexture
234 242
235 LastAssetID = asset.FullID; 243 LastAssetID = asset.FullID;
236 244
237
238 part.Shape.Textures = new LLObject.TextureEntry(asset.FullID); 245 part.Shape.Textures = new LLObject.TextureEntry(asset.FullID);
239 part.ScheduleFullUpdate(); 246 part.ScheduleFullUpdate();
240 } 247 }