diff options
author | onefang | 2020-09-08 21:17:45 +1000 |
---|---|---|
committer | onefang | 2020-09-08 21:17:45 +1000 |
commit | dcfd54b7608093d509cd045a152a4cde7317f66f (patch) | |
tree | 593eb822c05a6d209707593732e7e0fac4984663 /OpenSim/Region/CoreModules/World | |
parent | Various database fixups. (diff) | |
download | opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.zip opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.gz opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.bz2 opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.xz |
Move various paths out of the bin directory.
Diffstat (limited to 'OpenSim/Region/CoreModules/World')
-rw-r--r-- | OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs index 4c922ba..ce5e167 100644 --- a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs +++ b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs | |||
@@ -83,6 +83,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
83 | private bool m_texturePrims = true; // true if should texture the rendered prims | 83 | private bool m_texturePrims = true; // true if should texture the rendered prims |
84 | private float m_texturePrimSize = 48f; // size of prim before we consider texturing it | 84 | private float m_texturePrimSize = 48f; // size of prim before we consider texturing it |
85 | private bool m_renderMeshes = false; // true if to render meshes rather than just bounding boxes | 85 | private bool m_renderMeshes = false; // true if to render meshes rather than just bounding boxes |
86 | private String m_cacheDirectory = ""; | ||
86 | private float m_renderMinHeight = -100f; | 87 | private float m_renderMinHeight = -100f; |
87 | private float m_renderMaxHeight = 4096f; | 88 | private float m_renderMaxHeight = 4096f; |
88 | 89 | ||
@@ -119,6 +120,11 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
119 | Util.GetConfigVarFromSections<float>(m_config, "TexturePrimSize", configSections, m_texturePrimSize); | 120 | Util.GetConfigVarFromSections<float>(m_config, "TexturePrimSize", configSections, m_texturePrimSize); |
120 | m_renderMeshes = | 121 | m_renderMeshes = |
121 | Util.GetConfigVarFromSections<bool>(m_config, "RenderMeshes", configSections, m_renderMeshes); | 122 | Util.GetConfigVarFromSections<bool>(m_config, "RenderMeshes", configSections, m_renderMeshes); |
123 | m_cacheDirectory | ||
124 | = Util.GetConfigVarFromSections<string>(m_config, "CacheDirectory", configSections, System.IO.Path.Combine(Util.cacheDir(), "MapImageCache")); | ||
125 | |||
126 | if (!Directory.Exists(m_cacheDirectory)) | ||
127 | Directory.CreateDirectory(m_cacheDirectory); | ||
122 | 128 | ||
123 | m_renderMaxHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMaxHeight", configSections, m_renderMaxHeight); | 129 | m_renderMaxHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMaxHeight", configSections, m_renderMaxHeight); |
124 | m_renderMinHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMinHeight", configSections, m_renderMinHeight); | 130 | m_renderMinHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMinHeight", configSections, m_renderMinHeight); |
@@ -210,7 +216,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
210 | 216 | ||
211 | Bitmap tile = GenImage(); | 217 | Bitmap tile = GenImage(); |
212 | // image may be reloaded elsewhere, so no compression format | 218 | // image may be reloaded elsewhere, so no compression format |
213 | string filename = "MAP-" + m_scene.RegionInfo.RegionID.ToString() + ".png"; | 219 | string filename = System.IO.Path.Combine(m_cacheDirectory,"MAP-" + m_scene.RegionInfo.RegionID.ToString() + ".png"); |
214 | tile.Save(filename, ImageFormat.Png); | 220 | tile.Save(filename, ImageFormat.Png); |
215 | m_primMesher = null; | 221 | m_primMesher = null; |
216 | return tile; | 222 | return tile; |