Capture Webcam While Viewing It?

I am trying to make a webcam application in c# that allows users to record video. I have been using DirectShow.Net to preview the webcam and to take snapshots. But need to be able to capture video and audio while previewing the webcam at the same time. One thing I tried was using capturing multiple snapshots and converting them to a video using ffmpeg, however this obviously does not capture audio. Any ideas on how I could accomplish this?


Things you should be aware of:

  • Capture device is typically used exclusively, so can be used in a single graph
  • Graphs change state as a whole, you cannot stop a part of the graph, esp. to start/stop recording separately from previewing
  • The simplest is to create a graph which does both recording and preview:

    在DirectShow中捕获和预览滤波器图

    A more complicated scenario is to create 2 graphs for capture+preview and for recording and copy data from the first to the second, so that you could start/stop recording separately and seamlessly.

    链接地址: http://www.djcxy.com/p/80994.html

    上一篇: C#从网络摄像头捕捉图像

    下一篇: 在观看时捕获摄像头?