将网络视频流注册为虚拟摄像机 [英] Registering a network video stream as a virtual camera

查看:307
本文介绍了将网络视频流注册为虚拟摄像机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此,在过去的几周中,我一直试图解决此问题,但陷入停顿。我正在尝试将来自IP地址的RTSP流注册为虚拟网络摄像头,以用于其他应用程序(可以是Skype或类似的应用程序)。我需要的是计算机将虚拟网络摄像头添加到其设备列表中。最好通过C#脚本完成此操作,因为可以通过.NET程序动态添加设备。
我在StackOverflow上发现了类似的问题,但是其中许多已经过时,使用Linux或接收了其他流格式/协议。



到目前为止,我的方法一直是使用DirectShow过滤器,到目前为止,这种方法在一定程度上已经奏效。使用Graphedit,我可以使用RTSP源过滤器查看传入的流。但是,存在一些问题:




  • 源过滤器是一个试用版,完整版本已付费且相当昂贵

  • 我没有DirectShow过滤器编程的经验

  • 我只通过GraphEdit显示了流,没有注册虚拟驱动程序,因此Skype无法使用该流



所以我想我的问题可以归结为:




  • 我使用DirectShow的方法是实现我想要的唯一方法吗?

  • 如果Windows将流作为网络摄像头设备列出,则筛选器是使用的正确方法吗?

  • vcam还是最好的例子实现这样的事情?

  • 有人知道达到我所描述的类似开源程序吗?



无论如何,我感谢能获得的任何帮助!
谢谢。

解决方案




您正试图以某种方式安装下部的绿色或蓝色框,以便它从RTSP读取数据。



请注意,越来越多的应用程序(例如新的Skype)都基于Media Foundation(在图表的右上方),基于过滤器的源代码越来越不适用。



创建可以被各种软件识别的虚拟相机,前提是您要提供驱动程序(红色框)。即使存在这样的软件包,我也不知道有任何开源或免费的开源可让您快速开始使用此路线。



基于DirectShow过滤器的源(您尚未在其中实现RTSP客户端)只能由相同位的基于DirectShow的应用程序看到。


So I've tried to tackle this problem for the last couple of weeks but come to a bit of a standstill. I'm trying to registering an RTSP stream from an IP address as a virtual webcam for use in another application (could be skype or similar). What I need is for my computer to add a virtual webcam to its device list. This should preferably be done through a C# script as devices could be added dynamically through a .NET program. I have found similar questions on StackOverflow, but many of these are outdated, use Linux, or receives another stream format/protocol.

My approach so far has been using DirectShow filters and so far that has worked to a degree. Using Graphedit I can see my incoming stream by using an RTSP source filter. However, there are some problems:

  • The source filter was a trial, the full version is paid and pretty expensive
  • I have no experience with DirectShow filter programming
  • I only showed the stream through GraphEdit, there was no virtual driver registered so e.g Skype couldn't use the stream

So I guess my question boils down to:

  • Is my approach with DirectShow the only way to acheive what I'd like?
  • Is a filter the correct approach to use if Windows should list the stream as a webcam device?
  • Is vcam still the best example to look at to implement something like this?
  • Does any one know of similar, open source programs that acheive what I describe?

Anyway, I appreciate any help I can get! Thanks.

解决方案

The diagram below explains the applicability of virtual cameras:

You are trying to somehow mount a lower green or blue box so that it reads data from RTSP.

Note that more and more applications like new Skype are Media Foundation based (top right box on the diagram) and your filter based source is less and less applicable.

Creating a virtual camera which is recognized by various software assumes you are supplying a driver (red box). Even though such packages exist, I am not aware of any open source or even free which let you quickly start on this route.

DirectShow filter based sources (and you are yet to implement RTSP client there) will only be see by DirectShow based applications of the same bitness.

这篇关于将网络视频流注册为虚拟摄像机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆