Browse Source

change color for Visualize()

Kenkart 2 years ago
parent
commit
8900481b33
2 changed files with 2 additions and 4 deletions
  1. 0 2
      Assets/KinectView/Scripts/BodySourceView.cs
  2. 2 2
      Assets/Scripts/PlayerReplay.cs

+ 0 - 2
Assets/KinectView/Scripts/BodySourceView.cs

@@ -6,7 +6,6 @@ using Valve.VR;
 public class BodySourceView : MonoBehaviour
 {
     public Transform[] joints;
-    public Material BoneMaterial;
     public GameObject BodySourceManager;
     public Transform cameraRig;
     public PlayerReplay playerReplay;
@@ -142,7 +141,6 @@ public class BodySourceView : MonoBehaviour
             LineRenderer lr = jointObj.AddComponent<LineRenderer>();
             //lr.SetVertexCount(2);
             lr.positionCount = 2;
-            //lr.material = BoneMaterial;
             //lr.SetWidth(0.05f, 0.05f);
             lr.startWidth = 0.05f;
             lr.endWidth = 0.05f;

+ 2 - 2
Assets/Scripts/PlayerReplay.cs

@@ -11,7 +11,6 @@ public class PlayerReplay : MonoBehaviour
 
     public List<Vector3[]> jointsSequence = new List<Vector3[]>();
     public List<float> recordingTimes = new List<float>();
-    public Material boneMaterial;
     public Material transparentMat;
 
     public Visualizer_FadeIn vfi;
@@ -164,7 +163,8 @@ public class PlayerReplay : MonoBehaviour
                 GameObject jointObj = GameObject.CreatePrimitive(PrimitiveType.Cube);
                 LineRenderer lr = jointObj.AddComponent<LineRenderer>();
                 lr.positionCount = 2;
-                lr.material = boneMaterial;
+                lr.material = new Material(Shader.Find("Sprites/Default"));
+                lr.material.color = new Color(1, 0.8f, 0.6f);
                 lr.startWidth = 0.05f;
                 lr.endWidth = 0.05f;