mirror of
https://github.com/opensim/opensim.git
synced 2026-08-06 17:32:42 +08:00
add a few more parameters to llGetObjectDetails(); add intger log2(uint)
This commit is contained in:
@@ -203,14 +203,15 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
|
||||
m_primMesher = RenderingLoader.LoadRenderer(renderers[0]);
|
||||
}
|
||||
|
||||
viewWitdh = (int)m_scene.RegionInfo.RegionSizeX;
|
||||
viewHeight = (int)m_scene.RegionInfo.RegionSizeY;
|
||||
|
||||
cameraPos = new Vector3(
|
||||
(m_scene.RegionInfo.RegionSizeX) * 0.5f,
|
||||
(m_scene.RegionInfo.RegionSizeY) * 0.5f,
|
||||
viewWitdh * 0.5f,
|
||||
viewHeight * 0.5f,
|
||||
m_cameraHeight);
|
||||
|
||||
cameraDir = -Vector3.UnitZ;
|
||||
viewWitdh = (int)m_scene.RegionInfo.RegionSizeX;
|
||||
viewHeight = (int)m_scene.RegionInfo.RegionSizeY;
|
||||
orto = true;
|
||||
|
||||
Bitmap tile = GenImage();
|
||||
@@ -341,9 +342,8 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
|
||||
int bitWidth;
|
||||
int bitHeight;
|
||||
|
||||
const double log2inv = 1.4426950408889634073599246810019;
|
||||
bitWidth = (int)Math.Ceiling((Math.Log(terrain.Width) * log2inv));
|
||||
bitHeight = (int)Math.Ceiling((Math.Log(terrain.Height) * log2inv));
|
||||
bitWidth = Util.intLog2((uint)terrain.Width);
|
||||
bitHeight = Util.intLog2((uint)terrain.Height);
|
||||
|
||||
if (bitWidth > 8) // more than 256 is very heavy :(
|
||||
bitWidth = 8;
|
||||
|
||||
Reference in New Issue
Block a user