Merging two web cameras streaming into a single live streaming - Programmatically

Ahmad Alkhawaja picture Ahmad Alkhawaja · Sep 30, 2011 · Viewed 8.6k times · Source

I have two web cameras and I want to merge their streams into a single live streaming preview and display it to the screen.

I am skilled in C#/Java programming, could you please help me to find a framework that helps me to achieve this ?

Thanks,

Answer

yms picture yms · Oct 3, 2011

If you are aiming only at visualizing the two videos side by side, I would recommend taking a look at DirectShow.Net and GMFBridge toolkit.

Quote from GMFBridge site about the sample project GMFPlay included in the package:

GMFBridge: GMFPlay shows how to view multiple clips as a single movie

If you want to "merge" both streams (as drawing one on top of the other with some transparency level), then you could try this codeproject sample (for visualization only, also using DirectShow).

If you actually want to produce a new video stream and not only visualize, you could again use DirectShow combined with a mixing filter, Medialooks-Video-Mixer for example looks promissing.