How to write an own capture filter?

荒凉一梦 提交于 2019-12-04 06:32:47

问题


Here's a great article on capturing video: http://nerdlogger.com/2011/11/03/stream-your-windows-desktop-using-ffmpeg/ it uses UScreenCapture filter. This time I need to use a custom filter, how to write one? And how to register so that FFmpeg can see that?


回答1:


ffmpeg uses DirectShow video capture devices available in the opreating system, see more details on this forum thread: DirectShow Capture support.

So you need to make a counterpart virtual source device to be picked up by ffmpeg. Your resources are:

  • Multiple SO topics - Virtual webcam input as byte stream
  • Windows SDK - PushSource samples
  • VCam sample - Capture Source Filter



回答2:


Here's an open source one [if you want to go the dshow route] https://github.com/rdp/screen-capture-recorder-to-video-windows-free Another option would be some type of custom input filter to libav [ffmpeg].

You register it by [in administrator console] regsvr32 dll_name.dll



来源:https://stackoverflow.com/questions/10086897/how-to-write-an-own-capture-filter

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!