1
votes

I wrote a simple program for webcam capture using Directshow. Here is its graph: enter image description here

Here I create Smart Tee and connect it to my webcam. The first output pin goes to Null renderer, the second I try to connect to VMR-9 (Windowsless mode). After run I see Color Space Converter between the tee and VMR-9. Why? Does not VMR-9 support a direct connect for RGB24?

1

1 Answers

4
votes

You will typically see a conversion filter there because the video renderer not only does not support 24-bit RGB, but it also has additional requirements - its upstream connection filter needs to support extended strides. Many filters don't support that and Color Space Converter Filter works it around.

The Video Mixing Renderer filter (VMR-7 and VMR-9) will connect with any format that is supported by the graphics hardware on the system. [...] The VMR-9 always uses Direct3D for rendering, and allocates the underlying Direct3D surfaces when the upstream filter connects.

The graphics hardware may require a larger surface stride than the image width. In that case, the VMR requests a new format by calling QueryAccept. [...]