diff options
author | UbitUmarov | 2017-01-18 02:29:05 +0000 |
---|---|---|
committer | UbitUmarov | 2017-01-18 02:29:05 +0000 |
commit | e2c2d92d5aba757e459d0362c9b7392b528d5c8d (patch) | |
tree | 40afea5b0da8cc5996476384371f4dff1f74befa /OpenSim/Region/Framework/Scenes | |
parent | Permissions module: fix in prim inv CanEditNotecard group edit rights check (... (diff) | |
download | opensim-SC-e2c2d92d5aba757e459d0362c9b7392b528d5c8d.zip opensim-SC-e2c2d92d5aba757e459d0362c9b7392b528d5c8d.tar.gz opensim-SC-e2c2d92d5aba757e459d0362c9b7392b528d5c8d.tar.bz2 opensim-SC-e2c2d92d5aba757e459d0362c9b7392b528d5c8d.tar.xz |
antecipate baked cache check and Xbakes requests, so they happen before viewer check request (or force it to wait via locking).
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 59 |
1 files changed, 33 insertions, 26 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 9545c13..c4d4f8f 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -2029,11 +2029,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
2029 | m_log.DebugFormat("[CompleteMovement]: Missing COF for {0} is {1}", client.AgentId, COF); | 2029 | m_log.DebugFormat("[CompleteMovement]: Missing COF for {0} is {1}", client.AgentId, COF); |
2030 | } | 2030 | } |
2031 | 2031 | ||
2032 | // Tell the client that we're totally ready | ||
2033 | ControllingClient.MoveAgentIntoRegion(m_scene.RegionInfo, AbsolutePosition, look); | ||
2034 | |||
2035 | m_log.DebugFormat("[CompleteMovement] MoveAgentIntoRegion: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | ||
2036 | |||
2037 | if (!string.IsNullOrEmpty(m_callbackURI)) | 2032 | if (!string.IsNullOrEmpty(m_callbackURI)) |
2038 | { | 2033 | { |
2039 | // We cannot sleep here since this would hold up the inbound packet processing thread, as | 2034 | // We cannot sleep here since this would hold up the inbound packet processing thread, as |
@@ -2054,6 +2049,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2054 | 2049 | ||
2055 | Scene.SimulationService.ReleaseAgent(originID, UUID, m_callbackURI); | 2050 | Scene.SimulationService.ReleaseAgent(originID, UUID, m_callbackURI); |
2056 | m_callbackURI = null; | 2051 | m_callbackURI = null; |
2052 | m_log.DebugFormat("[CompleteMovement] ReleaseAgent: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | ||
2057 | } | 2053 | } |
2058 | // else | 2054 | // else |
2059 | // { | 2055 | // { |
@@ -2062,19 +2058,48 @@ namespace OpenSim.Region.Framework.Scenes | |||
2062 | // client.Name, client.AgentId, m_scene.RegionInfo.RegionName); | 2058 | // client.Name, client.AgentId, m_scene.RegionInfo.RegionName); |
2063 | // } | 2059 | // } |
2064 | 2060 | ||
2065 | m_log.DebugFormat("[CompleteMovement] ReleaseAgent: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | 2061 | |
2062 | // Tell the client that we're totally ready | ||
2063 | ControllingClient.MoveAgentIntoRegion(m_scene.RegionInfo, AbsolutePosition, look); | ||
2064 | m_log.DebugFormat("[CompleteMovement] MoveAgentIntoRegion: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | ||
2065 | |||
2066 | bool isHGTP = (m_teleportFlags & TeleportFlags.ViaHGLogin) != 0; | ||
2067 | |||
2068 | int delayctnr = Util.EnvironmentTickCount(); | ||
2069 | |||
2070 | if (!IsChildAgent) | ||
2071 | { | ||
2072 | // verify baked textures and cache | ||
2073 | bool cachedbaked = false; | ||
2074 | |||
2075 | if (IsNPC) | ||
2076 | cachedbaked = true; | ||
2077 | else | ||
2078 | { | ||
2079 | if (m_scene.AvatarFactory != null && !isHGTP) | ||
2080 | cachedbaked = m_scene.AvatarFactory.ValidateBakedTextureCache(this); | ||
2081 | |||
2082 | // not sure we need this | ||
2083 | if (!cachedbaked) | ||
2084 | { | ||
2085 | if (m_scene.AvatarFactory != null) | ||
2086 | m_scene.AvatarFactory.QueueAppearanceSave(UUID); | ||
2087 | } | ||
2088 | } | ||
2089 | m_log.DebugFormat("[CompleteMovement] Baked check: {0}ms", Util.EnvironmentTickCountSubtract(ts)); | ||
2090 | } | ||
2066 | 2091 | ||
2067 | if(m_teleportFlags > 0) | 2092 | if(m_teleportFlags > 0) |
2068 | { | 2093 | { |
2069 | gotCrossUpdate = false; // sanity check | 2094 | gotCrossUpdate = false; // sanity check |
2070 | Thread.Sleep(500); // let viewers catch us | 2095 | if(Util.EnvironmentTickCountSubtract(delayctnr)< 500) |
2096 | Thread.Sleep(500); // let viewers catch us | ||
2071 | } | 2097 | } |
2072 | 2098 | ||
2073 | if(!gotCrossUpdate) | 2099 | if(!gotCrossUpdate) |
2074 | RotateToLookAt(look); | 2100 | RotateToLookAt(look); |
2075 | 2101 | ||
2076 | // HG | 2102 | // HG |
2077 | bool isHGTP = (m_teleportFlags & TeleportFlags.ViaHGLogin) != 0; | ||
2078 | if(isHGTP) | 2103 | if(isHGTP) |
2079 | { | 2104 | { |
2080 | // ControllingClient.SendNameReply(m_uuid, Firstname, Lastname); | 2105 | // ControllingClient.SendNameReply(m_uuid, Firstname, Lastname); |
@@ -2101,24 +2126,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
2101 | 2126 | ||
2102 | if (!IsChildAgent) | 2127 | if (!IsChildAgent) |
2103 | { | 2128 | { |
2104 | // verify baked textures and cache | ||
2105 | bool cachedbaked = false; | ||
2106 | |||
2107 | if (IsNPC) | ||
2108 | cachedbaked = true; | ||
2109 | else | ||
2110 | { | ||
2111 | if (m_scene.AvatarFactory != null && !isHGTP) | ||
2112 | cachedbaked = m_scene.AvatarFactory.ValidateBakedTextureCache(this); | ||
2113 | |||
2114 | // not sure we need this | ||
2115 | if (!cachedbaked) | ||
2116 | { | ||
2117 | if (m_scene.AvatarFactory != null) | ||
2118 | m_scene.AvatarFactory.QueueAppearanceSave(UUID); | ||
2119 | } | ||
2120 | } | ||
2121 | |||
2122 | List<ScenePresence> allpresences = m_scene.GetScenePresences(); | 2129 | List<ScenePresence> allpresences = m_scene.GetScenePresences(); |
2123 | 2130 | ||
2124 | // send avatar object to all presences including us, so they cross it into region | 2131 | // send avatar object to all presences including us, so they cross it into region |