httptests
UbitUmarov 2018-05-18 05:31:45 +01:00
parent c7f3f3586d
commit 631308a1d1
2 changed files with 10 additions and 12 deletions

View File

@ -70,7 +70,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
private IRendering m_primMesher;
internal IJ2KDecoder m_imgDecoder;
// caches per rendering
// caches per rendering
private Dictionary<string, warp_Texture> m_warpTextures = new Dictionary<string, warp_Texture>();
private Dictionary<UUID, int> m_colors = new Dictionary<UUID, int>();
@ -239,7 +239,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
renderer.Scene.defaultCamera.setOrthographic(true, viewWitdh, viewHeigth);
else
renderer.Scene.defaultCamera.setFov(fov);
renderer.Scene.defaultCamera.setPos(pos);
renderer.Scene.defaultCamera.lookAt(lookat);
#endregion Camera
@ -442,7 +442,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
}
);
}
private void CreatePrim(WarpRenderer renderer, SceneObjectPart prim)
{
if ((PCode)prim.Shape.PCode != PCode.Prim)
@ -456,17 +456,15 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
if(screenFactor < 0)
return;
int p2 = (int)( -(float)Math.Log(screenFactor) * 1.442695f * 0.5 - 1);
int p2 = (int)(-(float)Math.Log(screenFactor) * 1.442695f * 0.5 - 1);
if(p2 < 0)
p2 = 0;
else if(p2>3)
else if(p2 > 3)
p2 = 3;
DetailLevel lod = (DetailLevel)(3 - p2);
// DetailLevel lod = DetailLevel.High;
FacetedMesh renderMesh = null;
Primitive omvPrim = prim.Shape.ToOmvPrimitive(prim.OffsetPosition, prim.RotationOffset);
@ -557,7 +555,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
warp_Vertex vert = new warp_Vertex(pos, v.TexCoord.X, v.TexCoord.Y);
faceObj.addVertex(vert);
}
}
}
else
{
float tu;
@ -601,10 +599,10 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
tv += offsetv;
vert = new warp_Vertex(pos, tu, tv);
}
faceObj.addVertex(vert);
}
}
}
for (int j = 0; j < face.Indices.Count; j += 3)
{
@ -719,7 +717,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
}
else
color = warp_Color.multiply(color, warp_Color.Grey);
mat.setColor(color);
renderer.Scene.addMaterial(materialName, mat);
@ -738,7 +736,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap
byte[] asset = m_scene.AssetService.GetData(id.ToString());
if (asset != null)
{
{
IJ2KDecoder imgDecoder = m_scene.RequestModuleInterface<IJ2KDecoder>();
try
{

Binary file not shown.