/// <summary>
        /// Unsuscribes from ArucoObjectController events, deactivates the trackers and abort the tracking thread and stops the tracking thread.
        /// </summary>
        protected override void Stopping()
        {
            base.Stopping();

            trackingThread.Stop();
            ArucoCamera.ImagesUpdated -= ArucoCamera_ImagesUpdated;

            ArucoObjectAdded   -= ArucoObjectsController_ArucoObjectAdded;
            ArucoObjectRemoved -= ArucoObjectsController_ArucoObjectRemoved;

            MarkerTracker.Deactivate();
            foreach (var tracker in additionalTrackers)
            {
                if (tracker.Value.IsActivated)
                {
                    tracker.Value.Deactivate();
                }
            }
        }
Esempio n. 2
0
            /// <summary>
            /// Unsuscribes from ArucoObjectController events, deactivates the trackers and abort the tracking thread and stops the tracking thread.
            /// </summary>
            public override void StopController()
            {
                base.StopController();

                trackingThread.Stop();

                ArucoObjectAdded   -= ArucoObjectsController_ArucoObjectAdded;
                ArucoObjectRemoved -= ArucoObjectsController_ArucoObjectRemoved;

                MarkerTracker.Deactivate();
                foreach (var tracker in additionalTrackers)
                {
                    if (tracker.Value.IsActivated)
                    {
                        tracker.Value.Deactivate();
                    }
                }

                OnStopped();
            }
 /// <summary>
 /// Unsusbcribes from <see cref="ArucoCamera.UndistortRectifyImages"/>.
 /// </summary>
 protected override void Stopping()
 {
     base.Stopping();
     remapThread.Stop();
     ArucoCamera.UndistortRectifyImages -= ArucoCamera_UndistortRectifyImages;
 }