views:

134

answers:

1

I'm capturing webcam using AForge so I've every frame as a bitmap. I would like to render some scene over it. Currently I am rendering DirectX (SlimDX) scene over C# Panel control.

Is there a possibility to put bitmap to ZBuffer or maybe some other way to achieve it?

A: 

To do this you need to insert a transform filter into the DirectShow graph. Basically You take in the video frame you convert it to a texture, render the video texture to the back of the frame buffer and then do whatever 3D rendering you wish to do over the top.

Its, by no means, a simple process. Directshow can get quite involved. The helper classes in the windows SDK help a lot, however. Alas though I'm not sure how you would then insert your filter into the graph in AForge ...

Goz