Configuration of persistent baked textures and save/send delays.

This commit is contained in:
Master ScienceSim
2010-10-28 12:00:04 -07:00
parent f2c1d0e34f
commit 68666efd25
3 changed files with 41 additions and 5 deletions

View File

@@ -31,6 +31,7 @@ using System.Collections.Generic;
using System.IO;
using System.Reflection;
using log4net;
using Nini.Config;
using OpenMetaverse;
using OpenSim.Framework.Servers;
using OpenSim.Framework.Servers.HttpServer;
@@ -112,6 +113,8 @@ namespace OpenSim.Framework.Capabilities
private string m_regionName;
private object m_fetchLock = new Object();
private bool m_persistBakedTextures = false;
public bool SSLCaps
{
get { return m_httpListener.UseSSL; }
@@ -145,6 +148,15 @@ namespace OpenSim.Framework.Capabilities
m_httpListenPort = httpPort;
m_persistBakedTextures = false;
IConfigSource config = m_Scene.Config;
if (config != null)
{
IConfig sconfig = config.Configs["Startup"];
if (sconfig != null)
m_persistBakedTextures = sconfig.GetBoolean("PersistBakedTextures",m_persistBakedTextures);
}
if (httpServer != null && httpServer.UseSSL)
{
m_httpListenPort = httpServer.SSLPort;
@@ -983,7 +995,7 @@ namespace OpenSim.Framework.Capabilities
asset = new AssetBase(assetID, "Baked Texture", (sbyte)AssetType.Texture, m_agentID.ToString());
asset.Data = data;
asset.Temporary = true;
asset.Local = true;
asset.Local = ! m_persistBakedTextures; // Local assets aren't persisted, non-local are
m_assetCache.Store(asset);
}