private void MoveBrowFromEye(EyeBrow brow, EyeTarget eye) { float yPosition = 0; float eyeAngleX = Humanoid.Tracking.Angle.Normalize(eye.target.transform.localEulerAngles.x); if (eyeAngleX < 0) { yPosition = -eyeAngleX * 0.0004F; } if (brow.outer.isPresent) { brow.outer.target.transform.localPosition = brow.outer.startPosition + Vector3.up * yPosition; brow.outer.target.confidence.position = 0.1F; } if (brow.center.isPresent) { brow.center.target.transform.localPosition = brow.center.startPosition + Vector3.up * yPosition; brow.center.target.confidence.position = 0.1F; } if (brow.inner.isPresent) { brow.inner.target.transform.localPosition = brow.inner.startPosition + Vector3.up * yPosition; brow.inner.target.confidence.position = 0.1F; } }
public void Start(EyeTarget _eyeTarget) { eyeTarget = _eyeTarget; }
private static void EyeTargetsInspector(EyeTarget eyeTarget) { EditorGUI.indentLevel++; eyeTarget.closed = EditorGUILayout.Slider("Close", eyeTarget.closed, 0, 1); EditorGUI.indentLevel--; }
private void UpdateEyeBrow(FaceTarget faceTarget, EyeBrow brow, EyeTarget eye) { UpdateFacePoint(faceTarget, brow.outer); UpdateFacePoint(faceTarget, brow.center); UpdateFacePoint(faceTarget, brow.inner); }