Touch.cs 944 B

12345678910111213141516171819202122232425262728293031323334
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using bbiwarg.Recognition.FingerRecognition;
  7. using bbiwarg.Recognition.PalmRecognition;
  8. using bbiwarg.Recognition.Tracking;
  9. using bbiwarg.Utility;
  10. using Emgu.CV;
  11. using Emgu.CV.Structure;
  12. namespace bbiwarg.Recognition.TouchRecognition
  13. {
  14. public class Touch : TrackableObject
  15. {
  16. public Vector2D AbsolutePosition { get; private set; }
  17. public Vector2D RelativePosition { get; private set; }
  18. public Finger Finger { get; private set; }
  19. public Palm Palm { get; private set; }
  20. public Touch(Vector2D absolutePosition, Finger finger, Palm palm)
  21. {
  22. AbsolutePosition = absolutePosition;
  23. RelativePosition = palm.getRelativePosition(absolutePosition);
  24. Finger = finger;
  25. Palm = palm;
  26. finger.Touch = this;
  27. }
  28. }
  29. }