General Graph-Building Techniques

[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

Every DirectShow application starts by building a filter graph. As you read the overview topics in the DirectShow documentation, you will find that most start by describing what kind of filter graph you need. In some cases, there is a method or a helper object specifically designed for building that type of graph. For example, the DVD Graph Builder object builds DVD playback graphs. In other cases, the application must construct the graph by adding filters and connecting them.

This section presents some helper functions that implement basic graph-building operations. They can be used by any DirectShow application that needs to build or modify a filter graph. This section contains the following topics:

Basic DirectShow Tasks

Enumerating Devices and Filters

Enumerating Objects in a Filter Graph

Intelligent Connect