protected void TestMotion(CaptureTesting captureTesting, MotionSensorTypes motionSensorType, MotionSensorSettingsTest settings)
        {
            captureId = captureTesting.captureId;

            if (motionSensorType == MotionSensorTypes.Motion2a)
            {
                using (MotionSensor2aTest test = new MotionSensor2aTest())
                {
                    test.settings = settings;

                    captureTesting.detectionStartTime    = DateTime.Now;
                    captureTesting.detectedMovmentFrames = new List <int>();
                    captureTesting.detectionMethod       = "a";

                    test.expectedFrames = captureTesting.numberFrames;
                    test.timedTest      = timedTest;
                    test.Run(captureTesting.captureId);

                    captureTesting.detectedMovmentFrames = test.movementFrames;
                    captureTesting.detectionEndTime      = DateTime.Now;

                    if (timedTest)
                    {
                        elapsedMilliseconds = test.testTimer.Elapsed.TotalMilliseconds;
                    }
                }

                WriteToDatabase(captureTesting, settings); //calls the subclass method
            }
        }
Exemple #2
0
        static void RunMotionTests_2a()
        {
            var motion = new Testing.MotionSensor2aTest();

            motion.settings = new MotionSensorSettingsTest();
            motion.settings.asynchronous = true;
            //motion.settings.framesToSkip = 20;
            //motion.settings.horizontalPixelsToSkip = 4;
            //motion.settings.verticalPixelsToSkip = 4;
            motion.Run(url, username, password);
            // motion.Run("2016220121715998");
        }
Exemple #3
0
        static void RunMotionTests_2b()
        {
            var motion = new Testing.MotionSensor2aTest();

            motion.Run("2016220121312251");
        }