void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.PCTSignaturesSQFD))
            {
                LogError("owner is not initialized. Add Action \"newPCTSignaturesSQFD\".");
                return;
            }
            OpenCVForUnity.Xfeatures2dModule.PCTSignaturesSQFD wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.PCTSignaturesSQFD, OpenCVForUnity.Xfeatures2dModule.PCTSignaturesSQFD>(owner);

            if (!(sourceSignature.Value is OpenCVForUnityPlayMakerActions.Mat))
            {
                LogError("sourceSignature is not initialized. Add Action \"newMat\".");
                return;
            }
            OpenCVForUnity.CoreModule.Mat wrapped_sourceSignature = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.Mat, OpenCVForUnity.CoreModule.Mat>(sourceSignature);

            List <OpenCVForUnity.CoreModule.Mat> wrapped_imageSignatures = new List <OpenCVForUnity.CoreModule.Mat>();

            OpenCVForUnityPlayMakerActionsUtils.ConvertFsmArrayToList <OpenCVForUnityPlayMakerActions.Mat, OpenCVForUnity.CoreModule.Mat>(imageSignatures, wrapped_imageSignatures);

            if (!(distances.Value is OpenCVForUnityPlayMakerActions.MatOfFloat))
            {
                LogError("distances is not initialized. Add Action \"newMatOfFloat\".");
                return;
            }
            OpenCVForUnity.CoreModule.MatOfFloat wrapped_distances = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.MatOfFloat, OpenCVForUnity.CoreModule.MatOfFloat>(distances);

            wrapped_owner.computeQuadraticFormDistances(wrapped_sourceSignature, wrapped_imageSignatures, wrapped_distances);

            OpenCVForUnityPlayMakerActionsUtils.ConvertListToFsmArray <OpenCVForUnity.CoreModule.Mat, OpenCVForUnityPlayMakerActions.Mat>(wrapped_imageSignatures, imageSignatures);
        }
Exemplo n.º 2
0
        void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.PCTSignaturesSQFD))
            {
                LogError("owner is not initialized. Add Action \"newPCTSignaturesSQFD\".");
                return;
            }
            OpenCVForUnity.Xfeatures2dModule.PCTSignaturesSQFD wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.PCTSignaturesSQFD, OpenCVForUnity.Xfeatures2dModule.PCTSignaturesSQFD>(owner);

            if (!(_signature0.Value is OpenCVForUnityPlayMakerActions.Mat))
            {
                LogError("_signature0 is not initialized. Add Action \"newMat\".");
                return;
            }
            OpenCVForUnity.CoreModule.Mat wrapped__signature0 = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.Mat, OpenCVForUnity.CoreModule.Mat>(_signature0);

            if (!(_signature1.Value is OpenCVForUnityPlayMakerActions.Mat))
            {
                LogError("_signature1 is not initialized. Add Action \"newMat\".");
                return;
            }
            OpenCVForUnity.CoreModule.Mat wrapped__signature1 = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.Mat, OpenCVForUnity.CoreModule.Mat>(_signature1);

            storeResult.Value = wrapped_owner.computeQuadraticFormDistance(wrapped__signature0, wrapped__signature1);
        }
Exemplo n.º 3
0
        //javadoc: PCTSignaturesSQFD::create()
        public static PCTSignaturesSQFD create()
        {
#if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
            PCTSignaturesSQFD retVal = PCTSignaturesSQFD.__fromPtr__(xfeatures2d_PCTSignaturesSQFD_create_13());

            return(retVal);
#else
            return(null);
#endif
        }
Exemplo n.º 4
0
        //javadoc: PCTSignaturesSQFD::create(distanceFunction, similarityFunction)
        public static PCTSignaturesSQFD create(int distanceFunction, int similarityFunction)
        {
#if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
            PCTSignaturesSQFD retVal = PCTSignaturesSQFD.__fromPtr__(xfeatures2d_PCTSignaturesSQFD_create_11(distanceFunction, similarityFunction));

            return(retVal);
#else
            return(null);
#endif
        }
Exemplo n.º 5
0
 /**
  * Creates the algorithm instance using selected distance function,
  * similarity function and similarity function parameter.
  * param distanceFunction Distance function selector. Default: L2
  * Available: L0_25, L0_5, L1, L2, L2SQUARED, L5, L_INFINITY
  * Available: MINUS, GAUSSIAN, HEURISTIC
  * return automatically generated
  */
 public static PCTSignaturesSQFD create(int distanceFunction)
 {
     return(PCTSignaturesSQFD.__fromPtr__(xfeatures2d_PCTSignaturesSQFD_create_12(distanceFunction)));
 }
Exemplo n.º 6
0
        //
        // C++: static Ptr_PCTSignaturesSQFD cv::xfeatures2d::PCTSignaturesSQFD::create(int distanceFunction = 3, int similarityFunction = 2, float similarityParameter = 1.0f)
        //

        /**
         * Creates the algorithm instance using selected distance function,
         * similarity function and similarity function parameter.
         * param distanceFunction Distance function selector. Default: L2
         * Available: L0_25, L0_5, L1, L2, L2SQUARED, L5, L_INFINITY
         * param similarityFunction Similarity function selector. Default: HEURISTIC
         * Available: MINUS, GAUSSIAN, HEURISTIC
         * param similarityParameter Parameter of the similarity function.
         * return automatically generated
         */
        public static PCTSignaturesSQFD create(int distanceFunction, int similarityFunction, float similarityParameter)
        {
            return(PCTSignaturesSQFD.__fromPtr__(xfeatures2d_PCTSignaturesSQFD_create_10(distanceFunction, similarityFunction, similarityParameter)));
        }
Exemplo n.º 7
0
 /**
  * Creates the algorithm instance using selected distance function,
  * similarity function and similarity function parameter.
  * Available: L0_25, L0_5, L1, L2, L2SQUARED, L5, L_INFINITY
  * Available: MINUS, GAUSSIAN, HEURISTIC
  * return automatically generated
  */
 public static PCTSignaturesSQFD create()
 {
     return(PCTSignaturesSQFD.__fromPtr__(xfeatures2d_PCTSignaturesSQFD_create_13()));
 }
 public PCTSignaturesSQFD(OpenCVForUnity.Xfeatures2dModule.PCTSignaturesSQFD nativeObj) : base(nativeObj)
 {
 }