|
@@ -142,14 +142,12 @@ public class BodySourceView : MonoBehaviour
|
|
|
//lr.SetVertexCount(2);
|
|
|
lr.positionCount = 2;
|
|
|
//lr.material = BoneMaterial;
|
|
|
- // TODO: change size of line
|
|
|
//lr.SetWidth(0.05f, 0.05f);
|
|
|
lr.startWidth = 0.05f;
|
|
|
lr.endWidth = 0.05f;
|
|
|
Material whiteDiffuseMat = new Material(Shader.Find("Unlit/Texture"));
|
|
|
lr.material = whiteDiffuseMat;
|
|
|
|
|
|
- // TODO: change size of cube
|
|
|
jointObj.transform.localScale = new Vector3(0.05f, 0.05f, 0.05f);
|
|
|
jointObj.name = jt.ToString();
|
|
|
jointObj.transform.parent = body.transform;
|
|
@@ -293,10 +291,10 @@ public class BodySourceView : MonoBehaviour
|
|
|
// TODO: change offset to be more realistic
|
|
|
if (joint.JointType == Kinect.JointType.ShoulderLeft)
|
|
|
{
|
|
|
- return new Vector3(joint.Position.X * -1 + 0.1f, joint.Position.Y * 1, joint.Position.Z * 1);
|
|
|
+ return new Vector3(joint.Position.X * -1 - 0.01f, joint.Position.Y * 1, joint.Position.Z * 1);
|
|
|
} else if (joint.JointType == Kinect.JointType.ShoulderRight)
|
|
|
{
|
|
|
- return new Vector3(joint.Position.X * -1 - 0.1f, joint.Position.Y * 1, joint.Position.Z * 1);
|
|
|
+ return new Vector3(joint.Position.X * -1 + 0.01f, joint.Position.Y * 1, joint.Position.Z * 1);
|
|
|
}
|
|
|
|
|
|
return new Vector3(joint.Position.X * -1, joint.Position.Y * 1, joint.Position.Z * 1);
|