Re-enables testing for config option mesh_sculpted_prim which was inadvertently disabled in a prior modification (oops) :)
parent
0d488ad489
commit
3035f5cb64
|
@ -759,7 +759,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
if (m_taintselected != m_isSelected)
|
if (m_taintselected != m_isSelected)
|
||||||
changeSelectedStatus(timestep);
|
changeSelectedStatus(timestep);
|
||||||
|
|
||||||
if (!m_taintVelocity.IsIdentical(PhysicsVector.Zero,0))
|
if (!m_taintVelocity.IsIdentical(PhysicsVector.Zero, 0.001f))
|
||||||
changevelocity(timestep);
|
changevelocity(timestep);
|
||||||
|
|
||||||
if (m_taintparent != _parent)
|
if (m_taintparent != _parent)
|
||||||
|
@ -918,18 +918,18 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
|
|
||||||
m_targetSpace = targetspace;
|
m_targetSpace = targetspace;
|
||||||
|
|
||||||
//if (_mesh == null)
|
if (_mesh == null)
|
||||||
//{
|
{
|
||||||
// if (_parent_scene.needsMeshing(_pbs))
|
if (_parent_scene.needsMeshing(_pbs))
|
||||||
// {
|
{
|
||||||
// // Don't need to re-enable body.. it's done in SetMesh
|
// Don't need to re-enable body.. it's done in SetMesh
|
||||||
// _mesh = _parent_scene.mesher.CreateMesh(m_primName, _pbs, _size, _parent_scene.meshSculptLOD, IsPhysical);
|
_mesh = _parent_scene.mesher.CreateMesh(m_primName, _pbs, _size, _parent_scene.meshSculptLOD, IsPhysical);
|
||||||
// // createmesh returns null when it's a shape that isn't a cube.
|
// createmesh returns null when it's a shape that isn't a cube.
|
||||||
// }
|
}
|
||||||
//}
|
}
|
||||||
|
|
||||||
if (_mesh == null )
|
//if (_mesh == null )
|
||||||
_mesh = _parent_scene.mesher.CreateMesh(m_primName, _pbs, _size, _parent_scene.meshSculptLOD, IsPhysical);
|
// _mesh = _parent_scene.mesher.CreateMesh(m_primName, _pbs, _size, _parent_scene.meshSculptLOD, IsPhysical);
|
||||||
|
|
||||||
|
|
||||||
lock (OdeScene.OdeLock)
|
lock (OdeScene.OdeLock)
|
||||||
|
@ -1323,7 +1323,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
// we don't need to do space calculation because the client sends a position update also.
|
// we don't need to do space calculation because the client sends a position update also.
|
||||||
|
|
||||||
// Construction of new prim
|
// Construction of new prim
|
||||||
//if (_parent_scene.needsMeshing(_pbs))
|
if (_parent_scene.needsMeshing(_pbs))
|
||||||
{
|
{
|
||||||
float meshlod = _parent_scene.meshSculptLOD;
|
float meshlod = _parent_scene.meshSculptLOD;
|
||||||
|
|
||||||
|
@ -1609,7 +1609,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
if (_size.Z <= 0) _size.Z = 0.01f;
|
if (_size.Z <= 0) _size.Z = 0.01f;
|
||||||
// Construction of new prim
|
// Construction of new prim
|
||||||
|
|
||||||
//if (_parent_scene.needsMeshing(_pbs))
|
if (_parent_scene.needsMeshing(_pbs))
|
||||||
{
|
{
|
||||||
// Don't need to re-enable body.. it's done in SetMesh
|
// Don't need to re-enable body.. it's done in SetMesh
|
||||||
float meshlod = _parent_scene.meshSculptLOD;
|
float meshlod = _parent_scene.meshSculptLOD;
|
||||||
|
|
|
@ -1174,16 +1174,17 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
//switch (pbs.ProfileShape)
|
//switch (pbs.ProfileShape)
|
||||||
//{
|
//{
|
||||||
// case ProfileShape.Square:
|
// case ProfileShape.Square:
|
||||||
/// support simple box & hollow box now; later, more shapes
|
// //support simple box & hollow box now; later, more shapes
|
||||||
//if (needsMeshing(pbs))
|
// if (needsMeshing(pbs))
|
||||||
//{
|
// {
|
||||||
// mesh = mesher.CreateMesh(primName, pbs, size, 32f, isPhysical);
|
// mesh = mesher.CreateMesh(primName, pbs, size, 32f, isPhysical);
|
||||||
//}
|
// }
|
||||||
|
|
||||||
// break;
|
// break;
|
||||||
//}
|
//}
|
||||||
|
|
||||||
mesh = mesher.CreateMesh(primName, pbs, size, 32f, isPhysical);
|
if (needsMeshing(pbs))
|
||||||
|
mesh = mesher.CreateMesh(primName, pbs, size, 32f, isPhysical);
|
||||||
|
|
||||||
result = AddPrim(primName, position, size, rotation, mesh, pbs, isPhysical);
|
result = AddPrim(primName, position, size, rotation, mesh, pbs, isPhysical);
|
||||||
|
|
||||||
|
@ -1523,14 +1524,18 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="pbs"></param>
|
/// <param name="pbs"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
//public bool needsMeshing(PrimitiveBaseShape pbs)
|
public bool needsMeshing(PrimitiveBaseShape pbs)
|
||||||
//{
|
{
|
||||||
|
// most of this is redundant now as the mesher will return null if it cant mesh a prim
|
||||||
|
// but we still need to check for sculptie meshing being enabled so this is the most
|
||||||
|
// convenient place to do it for now...
|
||||||
|
|
||||||
// //if (pbs.PathCurve == (byte)LLObject.PathCurve.Circle && pbs.ProfileCurve == (byte)LLObject.ProfileCurve.Circle && pbs.PathScaleY <= 0.75f)
|
// //if (pbs.PathCurve == (byte)LLObject.PathCurve.Circle && pbs.ProfileCurve == (byte)LLObject.ProfileCurve.Circle && pbs.PathScaleY <= 0.75f)
|
||||||
// //Console.WriteLine("needsMeshing: " + " pathCurve: " + pbs.PathCurve.ToString() + " profileCurve: " + pbs.ProfileCurve.ToString() + " pathScaleY: " + LLObject.UnpackPathScale(pbs.PathScaleY).ToString());
|
// //Console.WriteLine("needsMeshing: " + " pathCurve: " + pbs.PathCurve.ToString() + " profileCurve: " + pbs.ProfileCurve.ToString() + " pathScaleY: " + LLObject.UnpackPathScale(pbs.PathScaleY).ToString());
|
||||||
// if (pbs.SculptEntry && !meshSculptedPrim)
|
if (pbs.SculptEntry && !meshSculptedPrim)
|
||||||
// {
|
{
|
||||||
// return false;
|
return false;
|
||||||
// }
|
}
|
||||||
|
|
||||||
// if (pbs.ProfileHollow != 0)
|
// if (pbs.ProfileHollow != 0)
|
||||||
// return true;
|
// return true;
|
||||||
|
@ -1577,7 +1582,9 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
|
|
||||||
|
|
||||||
// return false;
|
// return false;
|
||||||
//}
|
|
||||||
|
return true; // assume the mesher will return a default shape or null and later code can deal with this
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Called after our prim properties are set Scale, position etc.
|
/// Called after our prim properties are set Scale, position etc.
|
||||||
|
@ -1763,7 +1770,7 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
|
|
||||||
lock (_activeprims)
|
lock (_activeprims)
|
||||||
{
|
{
|
||||||
if (timeStep < 0.2f)
|
//if (timeStep < 0.2f)
|
||||||
{
|
{
|
||||||
foreach (OdePrim actor in _activeprims)
|
foreach (OdePrim actor in _activeprims)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue