Exemplo n.º 1
0
 private void selectCaptureDeviceToolStripMenuItem_Click(object sender, EventArgs e)
 {
     using (CaptureDevice DevSelection = new CaptureDevice())
     {
         if (DevSelection.ShowDialog(this) == System.Windows.Forms.DialogResult.OK)
         {
             // Give this source to the CPlayer object for preview.
             HResult hr = m_pPreview.SetDevice(DevSelection.SelectedCaptureDevice);
             MFError.ThrowExceptionForHR(hr);
         }
     }
 }
Exemplo n.º 2
0
 private void selectCaptureDeviceToolStripMenuItem_Click(object sender, EventArgs e)
 {
     using (CaptureDevice DevSelection = new CaptureDevice())
     {
         if (DevSelection.ShowDialog(this) == System.Windows.Forms.DialogResult.OK)
         {
             // Give this source to the CPlayer object for preview.
             int hr = m_pPreview.SetDevice(DevSelection.SelectedCaptureDevice);
             MFError.ThrowExceptionForHR(hr);
         }
     }
 }