Exemple #1
0
        //javadoc: createBackgroundSubtractorKNN()
        public static BackgroundSubtractorKNN createBackgroundSubtractorKNN()
        {
#if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
            BackgroundSubtractorKNN retVal = BackgroundSubtractorKNN.__fromPtr__(video_Video_createBackgroundSubtractorKNN_13());

            return(retVal);
#else
            return(null);
#endif
        }
Exemple #2
0
        //
        // C++:  Ptr_BackgroundSubtractorKNN cv::createBackgroundSubtractorKNN(int history = 500, double dist2Threshold = 400.0, bool detectShadows = true)
        //

        //javadoc: createBackgroundSubtractorKNN(history, dist2Threshold, detectShadows)
        public static BackgroundSubtractorKNN createBackgroundSubtractorKNN(int history, double dist2Threshold, bool detectShadows)
        {
#if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
            BackgroundSubtractorKNN retVal = BackgroundSubtractorKNN.__fromPtr__(video_Video_createBackgroundSubtractorKNN_10(history, dist2Threshold, detectShadows));

            return(retVal);
#else
            return(null);
#endif
        }
        void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN))
            {
                LogError("owner is not initialized. Add Action \"newBackgroundSubtractorKNN\".");
                return;
            }
            OpenCVForUnity.VideoModule.BackgroundSubtractorKNN wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN, OpenCVForUnity.VideoModule.BackgroundSubtractorKNN>(owner);

            wrapped_owner.setShadowThreshold((float)threshold.Value);
        }
Exemple #4
0
        void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN))
            {
                LogError("owner is not initialized. Add Action \"newBackgroundSubtractorKNN\".");
                return;
            }
            OpenCVForUnity.VideoModule.BackgroundSubtractorKNN wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN, OpenCVForUnity.VideoModule.BackgroundSubtractorKNN>(owner);

            storeResult.Value = wrapped_owner.getHistory();
        }
Exemple #5
0
        void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN))
            {
                LogError("owner is not initialized. Add Action \"newBackgroundSubtractorKNN\".");
                return;
            }
            OpenCVForUnity.VideoModule.BackgroundSubtractorKNN wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN, OpenCVForUnity.VideoModule.BackgroundSubtractorKNN>(owner);

            if (!(storeResult.Value is OpenCVForUnityPlayMakerActions.Double))
            {
                storeResult.Value = new OpenCVForUnityPlayMakerActions.Double();
            }
            ((OpenCVForUnityPlayMakerActions.Double)storeResult.Value).wrappedObject = wrapped_owner.getShadowThreshold();
        }
Exemple #6
0
        void DoProcess()
        {
            if (!(owner.Value is OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN))
            {
                LogError("owner is not initialized. Add Action \"newBackgroundSubtractorKNN\".");
                return;
            }
            OpenCVForUnity.VideoModule.BackgroundSubtractorKNN wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.BackgroundSubtractorKNN, OpenCVForUnity.VideoModule.BackgroundSubtractorKNN>(owner);

            if (!(_dist2Threshold.Value is OpenCVForUnityPlayMakerActions.Double))
            {
                LogError("_dist2Threshold is not initialized. Add Action \"newDouble\".");
                return;
            }
            System.Double wrapped__dist2Threshold = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.Double, System.Double>(_dist2Threshold);

            wrapped_owner.setDist2Threshold(wrapped__dist2Threshold);
        }
 public BackgroundSubtractorKNN(OpenCVForUnity.VideoModule.BackgroundSubtractorKNN nativeObj) : base(nativeObj)
 {
 }