mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 08:55:56 +08:00
This is an experimental patch that adds support for comparing texture
hashes for the purpose of accurately responding to AgentTextureCached packets. There is a change to IClientAPI to report the wearbles hashes that come in through the SetAppearance packet. Added storage of the texture hashes in the appearance. While these are added to the Pack/Unpack (with support for missing values) routines (which means Simian will store them properly), they are not currently persisted in Robust.
This commit is contained in:
@@ -6214,7 +6214,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
if (appear.ObjectData.TextureEntry.Length > 1)
|
||||
te = new Primitive.TextureEntry(appear.ObjectData.TextureEntry, 0, appear.ObjectData.TextureEntry.Length);
|
||||
|
||||
handlerSetAppearance(sender, te, visualparams);
|
||||
List<CachedTextureRequestArg> hashes = new List<CachedTextureRequestArg>();
|
||||
for (int i = 0; i < appear.WearableData.Length; i++)
|
||||
{
|
||||
CachedTextureRequestArg arg = new CachedTextureRequestArg();
|
||||
arg.BakedTextureIndex = appear.WearableData[i].TextureIndex;
|
||||
arg.WearableHashID = appear.WearableData[i].CacheID;
|
||||
hashes.Add(arg);
|
||||
}
|
||||
|
||||
handlerSetAppearance(sender, te, visualparams, hashes);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
@@ -11487,12 +11496,20 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
requestArgs.Add(arg);
|
||||
}
|
||||
|
||||
CachedTextureRequest handlerCachedTextureRequest = OnCachedTextureRequest;
|
||||
if (handlerCachedTextureRequest != null)
|
||||
try
|
||||
{
|
||||
handlerCachedTextureRequest(simclient,cachedtex.AgentData.SerialNum,requestArgs);
|
||||
CachedTextureRequest handlerCachedTextureRequest = OnCachedTextureRequest;
|
||||
if (handlerCachedTextureRequest != null)
|
||||
{
|
||||
handlerCachedTextureRequest(simclient,cachedtex.AgentData.SerialNum,requestArgs);
|
||||
}
|
||||
}
|
||||
|
||||
catch (Exception e)
|
||||
{
|
||||
m_log.ErrorFormat("[CLIENT VIEW]: AgentTextureCached packet handler threw an exception, {0}", e);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user