Microsoft DirectX 8.1 (C++)

Using the Smart Tee Filter

When a filter provides separate capture and preview pins, you can capture from one while previewing from the other. However, even if the filter lacks a preview pin, you can do the same thing using the Smart Tee filter. This filter splits data from a capture pin into two identical streams, one for capture and one for preview.

The following illustration shows a graph with a Smart Tee filter.

Using the Smart Tee filter

To compensate for previewing and capturing from one pin, the Smart Tee filter performs two optimizations:

The second feature requires some explanation: Live data always arrives slightly late at the renderer filter, because of latency in the graph. If preview data is time-stamped, the renderer might drop frames in order to catch up. However, no matter how many frames it drops, every frame is still late. Removing the time stamps prevents the renderer from dropping frames unnecessarily. For more information, see Time and Clocks in DirectShow.

Note   You can treat a video port pin as a kind of preview pin, so a filter with a VP pin does not need a Smart Tee filter. However, VP pins have a few special requirements. The next section describes these requirements.