示例#1
0
        // Remove camera from the collection and signal to stop it
        public void Remove(Camera camera)
        {
            InnerList.Remove(camera);

            // signal to stop
            camera.SignalToStop();
        }
示例#2
0
        // Remove camera from the collection and signal to stop it
        public void Remove(Camera camera)
        {
            InnerList.Remove(camera);

            // signal to stop
            camera.SignalToStop();
        }
示例#3
0
        private void xCamSelect_Click(object sender, EventArgs e)
        {
            Program.Settings.Cam1.CamIndex = XCam_comboBox.SelectedIndex;

            while (camera.Active)
            {
                camera.SignalToStop();
                Thread.Sleep(50);
                camera.Active = false;
            }


            List <string> Monikers = camera.GetMonikerStrings();

            if (xCamera)
            {
                Program.Settings.Cam1.CamMoniker = Monikers[XCam_comboBox.SelectedIndex];
                AppSettings <Program.MySettings> .Save(Program.Settings);
            }
            else
            {
                Program.Settings.Cam2.CamMoniker = Monikers[XCam_comboBox.SelectedIndex];
                AppSettings <Program.MySettings> .Save(Program.Settings);
            }

            camera.MonikerString = Monikers[XCam_comboBox.SelectedIndex];

            camera.Active = true;

            camera.Start("DownCamera", Monikers[XCam_comboBox.SelectedIndex]);

            if (!camera.ReceivingFrames)
            {
                MessageBox.Show("Camera being used by another process");
            }
        }