Exemple #1
0
 public void LoadDetectionResults(List <DetectionResult> detectionResults)
 {
     foreach (var detectionResult in detectionResults)
     {
         var faceControl = new FaceControl();
         faceControl.FaceImageSource = detectionResult.ExtractFrame;
         int faceFrameSeconds = FaceImageHelper.ExtractSecondsInFaceImageName(detectionResult.ExtractFrame);
         faceControl.FaceName = string.Format("{0}s, {1}%", faceFrameSeconds, detectionResult.Confidence * 100);
         flpResult.Controls.Add(faceControl);
     }
 }
Exemple #2
0
	void InitializeEye()
	{
		if (faceControl == null)
			faceControl = transform.FindInParents<FaceControl>();
		if (faceControl == null)
			Debug.LogWarning("Eye without a FaceControl");
		if (center == null)
		{
			center = new GameObject(name + "_center").transform;
			center.position = transform.position;
			center.parent = transform.parent;
		}
	}
Exemple #3
0
 void initSpeaker()
 {
     _faceControl            = new FaceControl(ButtonEyeLeft, ButtonEyeRight, PlayNoseButton);
     _faceControl.FaceEvent += new FaceEventHandler(OnFaceEvent);
     _faceControl.Nerves     = NervesTrack.Value;
     _faceElems              = new Button[4];
     _faceElems[0]           = ButtonEyeLeft;
     _faceElems[1]           = ButtonEyeRight;
     _faceElems[2]           = PlayNoseButton;
     _faceElems[3]           = MouseButton;
     ButtonEyeLeft.Tag       = LeftEyeCenter;
     ButtonEyeRight.Tag      = RightEyeCenter;
     initProcessor((Form)_parent);
     _faceControl.StartAnimate();
     embedEyeCenter();
 }
Exemple #4
0
 void Awake()
 {
     centerServer = GameObject.Find("Center").GetComponent <CenterServer>();
     faceControl  = GameObject.Find("Face").GetComponent <FaceControl>();
     startClient("192.168.1.168", 5002);
 }
Exemple #5
0
 void Awake()
 {
     centerServer = GameObject.Find("Center").GetComponent <CenterServer>();
     faceControl  = GameObject.Find("Face").GetComponent <FaceControl>();
     startServer(5001);
 }
Exemple #6
0
 void Awake()
 {
     faceControl = GameObject.Find("Face").GetComponent <FaceControl>();
     startClient("192.168.1.135", 5003);
 }