From 4de10a45e9136c75e33f31b448720db35c2c23b1 Mon Sep 17 00:00:00 2001 From: Freaky Tech Date: Thu, 5 Mar 2015 23:52:13 +0100 Subject: revised GetMesh to not use intermediate base64 coding scheme it delivers binary and has binary as input. base64 intermediate coding makes no sense. Signed-off-by: BlueWall --- .../Handlers/GetMesh/GetMeshServerConnector.cs | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'OpenSim/Capabilities/Handlers/GetMesh/GetMeshServerConnector.cs') diff --git a/OpenSim/Capabilities/Handlers/GetMesh/GetMeshServerConnector.cs b/OpenSim/Capabilities/Handlers/GetMesh/GetMeshServerConnector.cs index 9c53862..19de3cf 100644 --- a/OpenSim/Capabilities/Handlers/GetMesh/GetMeshServerConnector.cs +++ b/OpenSim/Capabilities/Handlers/GetMesh/GetMeshServerConnector.cs @@ -25,16 +25,13 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections; using Nini.Config; -using OpenSim.Server.Base; -using OpenSim.Services.Interfaces; +using OpenMetaverse; using OpenSim.Framework.Servers.HttpServer; +using OpenSim.Server.Base; using OpenSim.Server.Handlers.Base; -using OpenSim.Framework.Servers; - -using OpenMetaverse; +using OpenSim.Services.Interfaces; +using System; namespace OpenSim.Capabilities.Handlers { @@ -65,8 +62,15 @@ namespace OpenSim.Capabilities.Handlers if (m_AssetService == null) throw new Exception(String.Format("Failed to load AssetService from {0}; config is {1}", assetService, m_ConfigName)); + string rurl = serverConfig.GetString("GetMeshRedirectURL"); + + server.AddStreamHandler( + new GetTextureHandler("/CAPS/GetMesh/" /*+ UUID.Random() */, m_AssetService, "GetMesh", null, rurl)); + + rurl = serverConfig.GetString("GetMesh2RedirectURL"); + server.AddStreamHandler( - new GetMeshHandler("/CAPS/GetMesh/" /*+ UUID.Random() */, m_AssetService, "GetMesh", null)); + new GetTextureHandler("/CAPS/GetMesh2/" /*+ UUID.Random() */, m_AssetService, "GetMesh2", null, rurl)); } } } \ No newline at end of file -- cgit v1.1