Пример #1
0
 internal static extern void setAutoStartCombinationRecognition([MarshalAs(UnmanagedType.U1)]bool enable, FubiPredefinedGestures.Combinations combinationID = FubiPredefinedGestures.Combinations.NUM_COMBINATIONS);
Пример #2
0
 internal static extern FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, IntPtr userStates, [MarshalAs(UnmanagedType.U1)]bool restart = true, [MarshalAs(UnmanagedType.U1)]bool returnFilteredData = false, [In, Out] FubiUtils.RecognitionCorrectionHint hint = null);
Пример #3
0
 internal static extern FubiUtils.RecognitionResult recognizeGestureOn(FubiPredefinedGestures.Postures postureID, UInt32 userID);
Пример #4
0
 internal static extern void enableCombinationRecognition(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, [MarshalAs(UnmanagedType.U1)]bool enable);
Пример #5
0
 internal static extern bool getAutoStartCombinationRecognition(FubiPredefinedGestures.Combinations combinationID = FubiPredefinedGestures.Combinations.NUM_COMBINATIONS);
Пример #6
0
 public static FubiUtils.RecognitionResult recognizeGestureOn(FubiPredefinedGestures.Postures postureID, UInt32 userID)
 {
     return FubiInternal.recognizeGestureOn(postureID, userID);
 }
Пример #7
0
 public static void setAutoStartCombinationRecognition(bool enable, FubiPredefinedGestures.Combinations combinationID = FubiPredefinedGestures.Combinations.NUM_COMBINATIONS)
 {
     FubiInternal.setAutoStartCombinationRecognition(enable, combinationID);
 }
Пример #8
0
 public static FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, out FubiTrackingData[] userStates,
     bool restart = true, bool returnFilteredData = false)
 {
     FubiUtils.RecognitionCorrectionHint dummy = new FubiUtils.RecognitionCorrectionHint();
     return getCombinationRecognitionProgressOn(combinationID, userID, out userStates, out dummy, restart, returnFilteredData);
 }
Пример #9
0
 public static FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, out FubiTrackingData[] userStates,
     out FubiUtils.RecognitionCorrectionHint correctionHint, bool restart = true, bool returnFilteredData = false)
 {
     IntPtr vec = FubiInternal.createTrackingDataVector();
     FubiUtils.RecognitionCorrectionHint hint = new FubiUtils.RecognitionCorrectionHint();
     FubiUtils.RecognitionResult recognized = FubiInternal.getCombinationRecognitionProgressOn(combinationID, userID, vec, restart, returnFilteredData, hint);
     correctionHint = hint;
     if (recognized == FubiUtils.RecognitionResult.RECOGNIZED)
     {
         UInt32 size = FubiInternal.getTrackingDataVectorSize(vec);
         userStates = new FubiTrackingData[size];
         for (UInt32 i = 0; i < size; i++)
         {
             IntPtr tInfo = FubiInternal.getTrackingData(vec, i);
             FubiTrackingData info = new FubiTrackingData();
             for (UInt32 j = 0; j < (uint)FubiUtils.SkeletonJoint.NUM_JOINTS; ++j)
             {
                 FubiInternal.getSkeletonJointPosition(tInfo, (FubiUtils.SkeletonJoint)j, out info.jointPositions[j].x, out info.jointPositions[j].y, out info.jointPositions[j].z, out info.jointPositions[j].confidence, out info.timeStamp);
                 double timeStamp = 0;
                 float[] rotMat = new float[9];
                 FubiInternal.getSkeletonJointOrientation(tInfo, (FubiUtils.SkeletonJoint)j, rotMat, out info.jointPositions[j].confidence, out timeStamp);
                 FubiUtils.Math.rotMatToRotation(rotMat, out info.jointOrientations[j].rx, out info.jointOrientations[j].ry, out info.jointOrientations[j].rz);
                 info.timeStamp = Math.Max(timeStamp, info.timeStamp);
             }
             userStates[i] = info;
         }
         FubiInternal.releaseTrackingDataVector(vec);
     }
     else
         userStates = null;
     return recognized;
 }
Пример #10
0
 public static FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, bool restart = true)
 {
     return FubiInternal.getCombinationRecognitionProgressOn(combinationID, userID, new IntPtr(0), restart, false);
 }
Пример #11
0
 public static FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, out FubiUtils.RecognitionCorrectionHint correctionHint, bool restart = true)
 {
     FubiUtils.RecognitionCorrectionHint hint = new FubiUtils.RecognitionCorrectionHint();
     FubiUtils.RecognitionResult res = FubiInternal.getCombinationRecognitionProgressOn(combinationID, userID, new IntPtr(0), restart, false, hint);
     correctionHint = hint;
     return res;
 }
Пример #12
0
 public static bool getAutoStartCombinationRecognition(FubiPredefinedGestures.Combinations combinationID = FubiPredefinedGestures.Combinations.NUM_COMBINATIONS)
 {
     return FubiInternal.getAutoStartCombinationRecognition(combinationID);
 }
Пример #13
0
 public static void enableCombinationRecognition(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, bool enable)
 {
     FubiInternal.enableCombinationRecognition(combinationID, userID, enable);
 }
Пример #14
0
 internal static extern FubiUtils.RecognitionResult getCombinationRecognitionProgressOn(FubiPredefinedGestures.Combinations combinationID, UInt32 userID, IntPtr userStates, [MarshalAs(UnmanagedType.U1)]bool restart = true);