AForge.NET

  :: AForge.NET Framework :: Articles :: Forums ::

Possible to use several cameras on the same capture card?

Forum to discuss AForge.NET Framework, its features, API, how-tos, etc.

Possible to use several cameras on the same capture card?

Postby c0dybrown » Mon Oct 14, 2019 9:10 pm

This seems to be a very complicated issue (at least for me) and I have spent many days trying to figure it out. It might not be possible.

I have a DirectShow capture card that splits video inputs using crossbar pins. I am able to easily manipulate this using AForge (which is awesome):

Code: Select all
videoCaptureDevice.CrossbarVideoInput = videoCaptureDevice.AvailableCrossbarVideoInputs[0];
videoCaptureDevice.CrossbarVideoInput = videoCaptureDevice.AvailableCrossbarVideoInputs[1];
videoCaptureDevice.CrossbarVideoInput = videoCaptureDevice.AvailableCrossbarVideoInputs[2];


I can easily view the camera streams individually and use the AForge framework with one camera. However, I am trying to view the streams from multiple crossbar inputs at once. I have tried many things here, such as alternating the crossbar inputs every other frame, using multiple VideoCaptureDevice instances, using separate threads, and many others. Nothing seems to work. I have tried digging into the DirectShow framework quite a bit as well, but none of the million search terms or examples I have used/seen apply to this issue.

I also cannot get iSpy Connect to work with these cameras and I tried reverse engineering and using some of their code with no success. The thing that bothers me is that I can use multiple cameras at the same time in Blue Iris! Of course, I do not know what they are using behind the scenes.

Does anyone have experience with something like this that might be able to point me in the right direction? Thanks!
c0dybrown
 
Posts: 3
Joined: Mon Oct 14, 2019 8:53 pm

Re: Possible to use several cameras on the same capture card

Postby andrew.kirillov » Tue Oct 15, 2019 8:22 am

Hard to say for sure, what is the issue. If Blue Iris uses Direct Show API, then we know it is possible (somehow). However, if it uses some API/SDK specific to the capture board, then it is different.

If Direct Show API does support it, then my feeling would be that we need only one video capture device object, but configure it somehow to get video output of all crossbar pins. This will require building more complicated Direct Show Capture Graph than the one built by AForge.NET. If you already started playing/digging into DirectShow, then I would suggest to spend some time with GraphEdit. There you can build a capture graph without any codding, just connecting different DirectShow filters together using UI. I suspect your crossbar may have multiple outputs and so may require connecting rendering/capturing filters to all them.
With best regards,
Andrew


Interested in supporting AForge.NET Framework?
User avatar
andrew.kirillov
Site Admin, AForge.NET Developer
 
Posts: 3453
Joined: Fri Jan 23, 2009 9:12 am
Location: UK




Return to AForge.NET Framework

cron