Пример #1
0
        private void Form1_Load(object sender, EventArgs e)
        {
            // Register the Webcam with a Cam that has no filter (I.e. just a normal video feed)
            wc = new Webcam(new List <Webcam.Cam> {
                new Webcam.Cam {
                    Box    = pb_left,
                    Filter = Filters.NoFilter
                }
            });

            try
            {
                wc.Start();
            }
            catch (NoCameraException)
            {
                MessageBox.Show("Kunne ikke finde en kamera enhed", "Intet kamera", MessageBoxButtons.OK, MessageBoxIcon.Error);
                Close();
            }
        }
Пример #2
0
 /// <summary>
 /// A Form for choosing video resolution
 /// </summary>
 /// <param name="webcam">Webcam whose resolutions to use as options</param>
 public VideoSettings(Webcam webcam)
 {
     InitializeComponent();
     this.webcam = webcam;
 }