BulletSim: correct some of the debugging input and output of PrimitiveBaseShape.

Whoever defined that structure was really into esoteric coding.
sedebug
Robert Adams 2015-01-04 13:52:14 -08:00
parent 5179f078f7
commit a617159f8b
2 changed files with 8 additions and 4 deletions

View File

@ -953,8 +953,10 @@ public sealed class BSScene : PhysicsScene, IPhysicsParameters
float pathShearY = pbs.PathShearY < 128 ? (float)pbs.PathShearY * 0.01f : (float)(pbs.PathShearY - 256) * 0.01f; float pathShearY = pbs.PathShearY < 128 ? (float)pbs.PathShearY * 0.01f : (float)(pbs.PathShearY - 256) * 0.01f;
float pathBegin = (float)pbs.PathBegin * 2.0e-5f; float pathBegin = (float)pbs.PathBegin * 2.0e-5f;
float pathEnd = 1.0f - (float)pbs.PathEnd * 2.0e-5f; float pathEnd = 1.0f - (float)pbs.PathEnd * 2.0e-5f;
float pathScaleX = (float)(pbs.PathScaleX - 100) * 0.01f; float pathScaleX = (float)(200 - pbs.PathScaleX) * 0.01f;
float pathScaleY = (float)(pbs.PathScaleY - 100) * 0.01f; float pathScaleY = (float)(200 - pbs.PathScaleY) * 0.01f;
float pathTaperX = pbs.PathTaperX * 0.01f;
float pathTaperY = pbs.PathTaperY * 0.01f;
float profileBegin = (float)pbs.ProfileBegin * 2.0e-5f; float profileBegin = (float)pbs.ProfileBegin * 2.0e-5f;
float profileEnd = 1.0f - (float)pbs.ProfileEnd * 2.0e-5f; float profileEnd = 1.0f - (float)pbs.ProfileEnd * 2.0e-5f;

View File

@ -135,6 +135,8 @@ public class HullCreation : OpenSimTestCase
pbs = PrimitiveBaseShape.CreateSphere(); pbs = PrimitiveBaseShape.CreateSphere();
pbs.ProfileShape = (byte)ProfileShape.Circle; pbs.ProfileShape = (byte)ProfileShape.Circle;
pbs.PathCurve = (byte)Extrusion.Curve1; pbs.PathCurve = (byte)Extrusion.Curve1;
pbs.PathScaleX = 100; // default hollow info as set in the viewer
pbs.PathScaleY = 25;
pos = new Vector3(120.0f, 120.0f, 0f); pos = new Vector3(120.0f, 120.0f, 0f);
pos.Z = PhysicsScene.TerrainManager.GetTerrainHeightAtXYZ(pos) + 10f; pos.Z = PhysicsScene.TerrainManager.GetTerrainHeightAtXYZ(pos) + 10f;
ObjectInitPosition = pos; ObjectInitPosition = pos;
@ -182,8 +184,8 @@ public class HullCreation : OpenSimTestCase
prim.PhysScene.DetailLog("{0}, mesh, shapeInfo={1}", prim.Name, mShape.shapeInfo); prim.PhysScene.DetailLog("{0}, mesh, shapeInfo={1}", prim.Name, mShape.shapeInfo);
break; break;
case "OpenSim.Region.Physics.BulletSPlugin.BSShapeHull": case "OpenSim.Region.Physics.BulletSPlugin.BSShapeHull":
// BSShapeHull hShape = physShape as BSShapeHull; BSShapeHull hShape = physShape as BSShapeHull;
// prim.PhysScene.DetailLog("{0}, hull, shapeInfo={1}", prim.Name, hShape.shapeInfo); prim.PhysScene.DetailLog("{0}, hull, shapeInfo={1}", prim.Name, hShape.shapeInfo);
break; break;
case "OpenSim.Region.Physics.BulletSPlugin.BSShapeConvexHull": case "OpenSim.Region.Physics.BulletSPlugin.BSShapeConvexHull":
BSShapeConvexHull chShape = physShape as BSShapeConvexHull; BSShapeConvexHull chShape = physShape as BSShapeConvexHull;